You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by dk...@apache.org on 2023/02/15 10:09:25 UTC

[cxf] branch main updated (077eb3b53a -> 751980b262)

This is an automated email from the ASF dual-hosted git repository.

dkulp pushed a change to branch main
in repository https://gitbox.apache.org/repos/asf/cxf.git


    from 077eb3b53a Update Micrometer to 1.10.4
     new 73a66684b9 Try to fix ws-discovery test on MacOS with vpn turned on
     new f16a87bdd0 Fix a bunch of checkstyle issues
     new c7441e5275 Couple of minor version updates
     new 751980b262 Update to use non-depracated APIs

The 4 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../cxf/bus/spring/Jsr250BeanPostProcessor.java    |  5 ++--
 .../cxf/common/util/SpringClasspathScanner.java    |  5 +---
 parent/pom.xml                                     |  8 +++----
 .../cxf/binding/soap/saaj/SAAJFactoryResolver.java |  1 -
 .../javascript/fortest/SimpleDocLitBareImpl.java   |  3 +--
 .../org/apache/cxf/jaxrs/openapi/SwaggerUi.java    |  1 -
 .../jetty/JettyWebSocketDestinationTest.java       |  1 +
 .../security/policy/interceptors/STSInvoker.java   |  5 ++--
 .../SpnegoContextTokenInInterceptor.java           |  2 +-
 .../cxf/ws/security/trust/AbstractSTSClient.java   |  5 ++--
 .../sts/token/provider/SymmetricKeyHandler.java    |  1 -
 .../systest/sts/batch/SimpleBatchSTSClient.java    |  4 ++--
 .../cxf/ws/discovery/WSDiscoveryClientTest.java    | 15 ++++++++----
 .../java/org/apache/cxf/wsn/jms/JmsPublisher.java  | 11 ++++-----
 .../java/org/apache/cxf/wsn/WsnBrokerTest.java     |  1 +
 .../cxf/systest/grizzly/EndpointAPITest.java       |  2 +-
 .../cxf/systest/grizzly/GrizzlyHttpContext.java    | 27 ++++++++++++++++++----
 .../cxf/systest/grizzly/GrizzlyHttpExchange.java   | 24 +++++++++++++++++--
 .../cxf/systest/grizzly/GrizzlyHttpHandler.java    | 18 +++++++++++++++
 .../apache/cxf/systest/jms/AbstractVmJMSTest.java  |  1 -
 20 files changed, 98 insertions(+), 42 deletions(-)


[cxf] 03/04: Couple of minor version updates

Posted by dk...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

dkulp pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/cxf.git

commit c7441e5275058a92738d95c876f7090630333f97
Author: Daniel Kulp <da...@kulp.com>
AuthorDate: Wed Feb 15 10:40:07 2023 +0100

    Couple of minor version updates
---
 parent/pom.xml | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/parent/pom.xml b/parent/pom.xml
index 6faf802d05..3003f2b20f 100644
--- a/parent/pom.xml
+++ b/parent/pom.xml
@@ -59,7 +59,7 @@
         <cxf.easymock.version>5.1.0</cxf.easymock.version>
 
         <!-- please maintain alphabetical order here -->
-        <cxf.activemq.artemis.version>2.27.1</cxf.activemq.artemis.version>
+        <cxf.activemq.artemis.version>2.28.0</cxf.activemq.artemis.version>
         <cxf.ahc.version>2.12.3</cxf.ahc.version>
         <cxf.arquillian.version>1.7.0.Alpha13</cxf.arquillian.version>
         <cxf.arquillian.weld.container.version>3.0.0.Final</cxf.arquillian.weld.container.version>
@@ -83,7 +83,7 @@
         <cxf.derby.version>10.16.1.1</cxf.derby.version>
         <cxf.dom4j.version>2.1.4</cxf.dom4j.version>
         <cxf.dropwizard3.version>3.2.6</cxf.dropwizard3.version>
-        <cxf.dropwizard4.version>4.2.15</cxf.dropwizard4.version>
+        <cxf.dropwizard4.version>4.2.16</cxf.dropwizard4.version>
         <cxf.ehcache3.version>3.10.8</cxf.ehcache3.version>
         <cxf.el-api.version>3.0.3</cxf.el-api.version>
         <cxf.findbugs.version>3.0.2</cxf.findbugs.version>
@@ -112,7 +112,7 @@
         <cxf.jaeger.version>1.8.1</cxf.jaeger.version>
         <cxf.jaeger.version>1.6.0</cxf.jaeger.version>
         <cxf.jakarta.activation.version>2.1.0</cxf.jakarta.activation.version>
-        <cxf.jakarta.mail.version>2.1.0</cxf.jakarta.mail.version>
+        <cxf.jakarta.mail.version>2.1.1</cxf.jakarta.mail.version>
         <cxf.jakarta.injectapi.version>2.0.1</cxf.jakarta.injectapi.version>
         <cxf.jakarta.jwsapi.version>3.0.0</cxf.jakarta.jwsapi.version>
         <cxf.jakarta.soapapi.version>2.0.1</cxf.jakarta.soapapi.version>
@@ -731,7 +731,7 @@
             <dependency>
                 <groupId>com.sun.xml.fastinfoset</groupId>
                 <artifactId>FastInfoset</artifactId>
-                <version>2.0.0</version>
+                <version>2.1.0</version>
                 <exclusions>
                     <exclusion>
                         <groupId>javax.xml</groupId>


[cxf] 01/04: Try to fix ws-discovery test on MacOS with vpn turned on

Posted by dk...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

dkulp pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/cxf.git

commit 73a66684b95eaf304ab91e87c8ce22b024829220
Author: Daniel Kulp <da...@kulp.com>
AuthorDate: Wed Feb 15 10:36:25 2023 +0100

    Try to fix ws-discovery test on MacOS with vpn turned on
---
 .../java/org/apache/cxf/ws/discovery/WSDiscoveryClientTest.java     | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/services/ws-discovery/ws-discovery-api/src/test/java/org/apache/cxf/ws/discovery/WSDiscoveryClientTest.java b/services/ws-discovery/ws-discovery-api/src/test/java/org/apache/cxf/ws/discovery/WSDiscoveryClientTest.java
index aa8f8684a9..8b520d3574 100644
--- a/services/ws-discovery/ws-discovery-api/src/test/java/org/apache/cxf/ws/discovery/WSDiscoveryClientTest.java
+++ b/services/ws-discovery/ws-discovery-api/src/test/java/org/apache/cxf/ws/discovery/WSDiscoveryClientTest.java
@@ -73,6 +73,11 @@ public final class WSDiscoveryClientTest {
                 }
             }
         }
+        for (NetworkInterface p : possibles) {
+            if (p.isPointToPoint()) {
+                return p;
+            }
+        }
         return possibles.isEmpty() ? null : possibles.get(possibles.size() - 1);
     }
 
@@ -142,7 +147,6 @@ public final class WSDiscoveryClientTest {
             }
         }).start();
 
-
         Bus bus = BusFactory.newInstance().createBus();
         WSDiscoveryClient c = new WSDiscoveryClient(bus);
         c.setVersion10();


[cxf] 04/04: Update to use non-depracated APIs

Posted by dk...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

dkulp pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/cxf.git

commit 751980b26229ae7bb3bc239ac18f9b74bb7ecf8c
Author: Daniel Kulp <da...@kulp.com>
AuthorDate: Wed Feb 15 10:57:16 2023 +0100

    Update to use non-depracated APIs
---
 .../java/org/apache/cxf/ws/discovery/WSDiscoveryClientTest.java  | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/services/ws-discovery/ws-discovery-api/src/test/java/org/apache/cxf/ws/discovery/WSDiscoveryClientTest.java b/services/ws-discovery/ws-discovery-api/src/test/java/org/apache/cxf/ws/discovery/WSDiscoveryClientTest.java
index 8b520d3574..eac0772155 100644
--- a/services/ws-discovery/ws-discovery-api/src/test/java/org/apache/cxf/ws/discovery/WSDiscoveryClientTest.java
+++ b/services/ws-discovery/ws-discovery-api/src/test/java/org/apache/cxf/ws/discovery/WSDiscoveryClientTest.java
@@ -22,10 +22,12 @@ package org.apache.cxf.ws.discovery;
 import java.io.InputStream;
 import java.net.DatagramPacket;
 import java.net.InetAddress;
+import java.net.InetSocketAddress;
 import java.net.InterfaceAddress;
 import java.net.MulticastSocket;
 import java.net.NetworkInterface;
 import java.net.SocketAddress;
+import java.net.StandardSocketOptions;
 import java.nio.charset.StandardCharsets;
 import java.util.ArrayList;
 import java.util.Enumeration;
@@ -114,10 +116,11 @@ public final class WSDiscoveryClientTest {
                     InetAddress address = InetAddress.getByName("239.255.255.250");
                     MulticastSocket s = new MulticastSocket(Integer.parseInt(PORT));
                     s.setBroadcast(true);
-                    s.setNetworkInterface(findIpv4Interface());
-                    s.setLoopbackMode(false);
+                    NetworkInterface ni = findIpv4Interface();
+                    s.setNetworkInterface(ni);
+                    s.setOption(StandardSocketOptions.IP_MULTICAST_LOOP, false);
                     s.setReuseAddress(true);
-                    s.joinGroup(address);
+                    s.joinGroup(new InetSocketAddress(address, 0), ni);
                     s.setReceiveBufferSize(64 * 1024);
                     s.setSoTimeout(5000);
                     byte[] bytes = new byte[64 * 1024];


[cxf] 02/04: Fix a bunch of checkstyle issues

Posted by dk...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

dkulp pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/cxf.git

commit f16a87bdd0cedd82af9d62729c0d7418aa0e81a0
Author: Daniel Kulp <da...@kulp.com>
AuthorDate: Wed Feb 15 10:39:35 2023 +0100

    Fix a bunch of checkstyle issues
---
 .../cxf/bus/spring/Jsr250BeanPostProcessor.java    |  5 ++--
 .../cxf/common/util/SpringClasspathScanner.java    |  5 +---
 .../cxf/binding/soap/saaj/SAAJFactoryResolver.java |  1 -
 .../javascript/fortest/SimpleDocLitBareImpl.java   |  3 +--
 .../org/apache/cxf/jaxrs/openapi/SwaggerUi.java    |  1 -
 .../jetty/JettyWebSocketDestinationTest.java       |  1 +
 .../security/policy/interceptors/STSInvoker.java   |  5 ++--
 .../SpnegoContextTokenInInterceptor.java           |  2 +-
 .../cxf/ws/security/trust/AbstractSTSClient.java   |  5 ++--
 .../sts/token/provider/SymmetricKeyHandler.java    |  1 -
 .../systest/sts/batch/SimpleBatchSTSClient.java    |  4 ++--
 .../java/org/apache/cxf/wsn/jms/JmsPublisher.java  | 11 ++++-----
 .../java/org/apache/cxf/wsn/WsnBrokerTest.java     |  1 +
 .../cxf/systest/grizzly/EndpointAPITest.java       |  2 +-
 .../cxf/systest/grizzly/GrizzlyHttpContext.java    | 27 ++++++++++++++++++----
 .../cxf/systest/grizzly/GrizzlyHttpExchange.java   | 24 +++++++++++++++++--
 .../cxf/systest/grizzly/GrizzlyHttpHandler.java    | 18 +++++++++++++++
 .../apache/cxf/systest/jms/AbstractVmJMSTest.java  |  1 -
 18 files changed, 83 insertions(+), 34 deletions(-)

diff --git a/core/src/main/java/org/apache/cxf/bus/spring/Jsr250BeanPostProcessor.java b/core/src/main/java/org/apache/cxf/bus/spring/Jsr250BeanPostProcessor.java
index f429d3de1f..7a9f145d79 100644
--- a/core/src/main/java/org/apache/cxf/bus/spring/Jsr250BeanPostProcessor.java
+++ b/core/src/main/java/org/apache/cxf/bus/spring/Jsr250BeanPostProcessor.java
@@ -47,8 +47,9 @@ public class Jsr250BeanPostProcessor
     public void setApplicationContext(ApplicationContext applicationContext) {
         context = applicationContext;
         try {
-            Class<?> cls = ClassLoaderUtils.loadClass("org.springframework.context.annotation.CommonAnnotationBeanPostProcessor",
-                                                      applicationContext.getClass());
+            Class<?> cls = ClassLoaderUtils
+                .loadClass("org.springframework.context.annotation.CommonAnnotationBeanPostProcessor",
+                           applicationContext.getClass());
             isProcessing = context.getBeanNamesForType(cls, true, false).length == 0;
         } catch (ClassNotFoundException e) {
             isProcessing = true;
diff --git a/core/src/main/java/org/apache/cxf/common/util/SpringClasspathScanner.java b/core/src/main/java/org/apache/cxf/common/util/SpringClasspathScanner.java
index 16d925ce3f..75828610b1 100644
--- a/core/src/main/java/org/apache/cxf/common/util/SpringClasspathScanner.java
+++ b/core/src/main/java/org/apache/cxf/common/util/SpringClasspathScanner.java
@@ -41,10 +41,7 @@ import org.springframework.util.ClassUtils;
 class SpringClasspathScanner extends ClasspathScanner {
 
     //TODO: [OSGi+Jakarta] uncoment this when osgi comes back
-    //private static final boolean IN_OSGI =  isSpringInOsgi();
-    private static final boolean IN_OSGI = false;
-
-    
+    //private static final boolean IN_OSGI =  isSpringInOsgi();    
     
     SpringClasspathScanner() throws Exception {
         Class.forName("org.springframework.core.io.support.PathMatchingResourcePatternResolver");
diff --git a/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/saaj/SAAJFactoryResolver.java b/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/saaj/SAAJFactoryResolver.java
index 47a81df7b4..2405adcd52 100644
--- a/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/saaj/SAAJFactoryResolver.java
+++ b/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/saaj/SAAJFactoryResolver.java
@@ -25,7 +25,6 @@ import jakarta.xml.soap.MessageFactory;
 import jakarta.xml.soap.SOAPConstants;
 import jakarta.xml.soap.SOAPException;
 import jakarta.xml.soap.SOAPFactory;
-
 import org.apache.cxf.binding.soap.Soap11;
 import org.apache.cxf.binding.soap.Soap12;
 import org.apache.cxf.binding.soap.SoapVersion;
diff --git a/rt/javascript/javascript-tests/src/test/java/org/apache/cxf/javascript/fortest/SimpleDocLitBareImpl.java b/rt/javascript/javascript-tests/src/test/java/org/apache/cxf/javascript/fortest/SimpleDocLitBareImpl.java
index 538ef18c13..473bdb7309 100644
--- a/rt/javascript/javascript-tests/src/test/java/org/apache/cxf/javascript/fortest/SimpleDocLitBareImpl.java
+++ b/rt/javascript/javascript-tests/src/test/java/org/apache/cxf/javascript/fortest/SimpleDocLitBareImpl.java
@@ -19,11 +19,10 @@
 
 package org.apache.cxf.javascript.fortest;
 
-import java.sql.Time;
 import java.util.concurrent.CountDownLatch;
+import java.util.concurrent.TimeUnit;
 
 import jakarta.jws.WebService;
-import java.util.concurrent.TimeUnit;
 
 /**
  *
diff --git a/rt/rs/description-openapi-v3/src/main/java/org/apache/cxf/jaxrs/openapi/SwaggerUi.java b/rt/rs/description-openapi-v3/src/main/java/org/apache/cxf/jaxrs/openapi/SwaggerUi.java
index 09207b6fb9..1b37e6c3dd 100644
--- a/rt/rs/description-openapi-v3/src/main/java/org/apache/cxf/jaxrs/openapi/SwaggerUi.java
+++ b/rt/rs/description-openapi-v3/src/main/java/org/apache/cxf/jaxrs/openapi/SwaggerUi.java
@@ -20,7 +20,6 @@
 package org.apache.cxf.jaxrs.openapi;
 import org.apache.cxf.jaxrs.swagger.ui.SwaggerUiResolver;
 
-import io.swagger.v3.oas.annotations.OpenAPIDefinition;
 
 /**
  * SwaggerUI resolvers implementation for OpenAPI 
diff --git a/rt/transports/websocket/src/test/java/org/apache/cxf/transport/websocket/jetty/JettyWebSocketDestinationTest.java b/rt/transports/websocket/src/test/java/org/apache/cxf/transport/websocket/jetty/JettyWebSocketDestinationTest.java
index b04bc323ba..16a3e9fea0 100644
--- a/rt/transports/websocket/src/test/java/org/apache/cxf/transport/websocket/jetty/JettyWebSocketDestinationTest.java
+++ b/rt/transports/websocket/src/test/java/org/apache/cxf/transport/websocket/jetty/JettyWebSocketDestinationTest.java
@@ -31,6 +31,7 @@ import org.apache.cxf.transport.http.HTTPTransportFactory;
 import org.apache.cxf.transport.http_jetty.JettyHTTPServerEngine;
 import org.apache.cxf.transport.http_jetty.JettyHTTPServerEngineFactory;
 import org.apache.cxf.transport.websocket.jetty11.Jetty11WebSocketDestination;
+
 import org.easymock.EasyMock;
 import org.easymock.IMocksControl;
 import org.junit.Before;
diff --git a/rt/ws/security/src/main/java/org/apache/cxf/ws/security/policy/interceptors/STSInvoker.java b/rt/ws/security/src/main/java/org/apache/cxf/ws/security/policy/interceptors/STSInvoker.java
index ccd0f2f55b..eba9f1ca0a 100644
--- a/rt/ws/security/src/main/java/org/apache/cxf/ws/security/policy/interceptors/STSInvoker.java
+++ b/rt/ws/security/src/main/java/org/apache/cxf/ws/security/policy/interceptors/STSInvoker.java
@@ -27,8 +27,6 @@ import java.util.logging.Logger;
 import javax.xml.stream.XMLStreamException;
 import javax.xml.transform.dom.DOMSource;
 
-import org.apache.xml.security.exceptions.XMLSecurityException;
-import org.apache.xml.security.stax.ext.XMLSecurityConstants;
 import org.w3c.dom.Document;
 import org.w3c.dom.Element;
 import org.w3c.dom.Node;
@@ -56,7 +54,8 @@ import org.apache.wss4j.common.token.Reference;
 import org.apache.wss4j.common.token.SecurityTokenReference;
 import org.apache.wss4j.common.util.DateUtil;
 import org.apache.wss4j.dom.message.token.SecurityContextToken;
-import org.apache.wss4j.dom.util.WSSecurityUtil;
+import org.apache.xml.security.exceptions.XMLSecurityException;
+import org.apache.xml.security.stax.ext.XMLSecurityConstants;
 import org.apache.xml.security.utils.XMLUtils;
 
 /**
diff --git a/rt/ws/security/src/main/java/org/apache/cxf/ws/security/policy/interceptors/SpnegoContextTokenInInterceptor.java b/rt/ws/security/src/main/java/org/apache/cxf/ws/security/policy/interceptors/SpnegoContextTokenInInterceptor.java
index 328e159055..0492c1088d 100644
--- a/rt/ws/security/src/main/java/org/apache/cxf/ws/security/policy/interceptors/SpnegoContextTokenInInterceptor.java
+++ b/rt/ws/security/src/main/java/org/apache/cxf/ws/security/policy/interceptors/SpnegoContextTokenInInterceptor.java
@@ -24,7 +24,6 @@ import java.util.Collection;
 
 import javax.security.auth.callback.CallbackHandler;
 
-import org.apache.xml.security.stax.ext.XMLSecurityConstants;
 import org.w3c.dom.Element;
 
 import org.apache.cxf.binding.soap.SoapBindingConstants;
@@ -62,6 +61,7 @@ import org.apache.wss4j.common.spnego.SpnegoTokenContext;
 import org.apache.wss4j.dom.engine.WSSConfig;
 import org.apache.wss4j.dom.message.token.SecurityContextToken;
 import org.apache.wss4j.policy.SPConstants;
+import org.apache.xml.security.stax.ext.XMLSecurityConstants;
 import org.apache.xml.security.utils.XMLUtils;
 
 class SpnegoContextTokenInInterceptor extends AbstractPhaseInterceptor<SoapMessage> {
diff --git a/rt/ws/security/src/main/java/org/apache/cxf/ws/security/trust/AbstractSTSClient.java b/rt/ws/security/src/main/java/org/apache/cxf/ws/security/trust/AbstractSTSClient.java
index d25ef285ff..d95294581e 100755
--- a/rt/ws/security/src/main/java/org/apache/cxf/ws/security/trust/AbstractSTSClient.java
+++ b/rt/ws/security/src/main/java/org/apache/cxf/ws/security/trust/AbstractSTSClient.java
@@ -50,8 +50,6 @@ import javax.xml.stream.XMLStreamException;
 import javax.xml.stream.XMLStreamWriter;
 import javax.xml.transform.dom.DOMSource;
 
-import org.apache.xml.security.exceptions.XMLSecurityException;
-import org.apache.xml.security.stax.ext.XMLSecurityConstants;
 import org.w3c.dom.Document;
 import org.w3c.dom.Element;
 import org.w3c.dom.Node;
@@ -146,9 +144,12 @@ import org.apache.wss4j.policy.model.SignedParts;
 import org.apache.wss4j.policy.model.Trust10;
 import org.apache.wss4j.policy.model.Trust13;
 import org.apache.xml.security.exceptions.Base64DecodingException;
+import org.apache.xml.security.exceptions.XMLSecurityException;
 import org.apache.xml.security.keys.content.X509Data;
 import org.apache.xml.security.keys.content.keyvalues.DSAKeyValue;
 import org.apache.xml.security.keys.content.keyvalues.RSAKeyValue;
+import org.apache.xml.security.stax.ext.XMLSecurityConstants;
+
 
 /**
  * An abstract class with some functionality to invoke on a SecurityTokenService (STS) via the
diff --git a/services/sts/sts-core/src/main/java/org/apache/cxf/sts/token/provider/SymmetricKeyHandler.java b/services/sts/sts-core/src/main/java/org/apache/cxf/sts/token/provider/SymmetricKeyHandler.java
index 79df00e99d..66d2133ec6 100644
--- a/services/sts/sts-core/src/main/java/org/apache/cxf/sts/token/provider/SymmetricKeyHandler.java
+++ b/services/sts/sts-core/src/main/java/org/apache/cxf/sts/token/provider/SymmetricKeyHandler.java
@@ -33,7 +33,6 @@ import org.apache.cxf.ws.security.sts.provider.STSException;
 import org.apache.wss4j.common.WSS4JConstants;
 import org.apache.wss4j.common.derivedKey.P_SHA1;
 import org.apache.wss4j.common.ext.WSSecurityException;
-import org.apache.wss4j.dom.util.WSSecurityUtil;
 import org.apache.xml.security.exceptions.XMLSecurityException;
 import org.apache.xml.security.stax.ext.XMLSecurityConstants;
 
diff --git a/services/sts/systests/advanced/src/test/java/org/apache/cxf/systest/sts/batch/SimpleBatchSTSClient.java b/services/sts/systests/advanced/src/test/java/org/apache/cxf/systest/sts/batch/SimpleBatchSTSClient.java
index 0d73ef9501..e57299b023 100644
--- a/services/sts/systests/advanced/src/test/java/org/apache/cxf/systest/sts/batch/SimpleBatchSTSClient.java
+++ b/services/sts/systests/advanced/src/test/java/org/apache/cxf/systest/sts/batch/SimpleBatchSTSClient.java
@@ -41,8 +41,6 @@ import javax.xml.stream.XMLStreamException;
 import javax.xml.stream.XMLStreamWriter;
 import javax.xml.transform.dom.DOMSource;
 
-import org.apache.xml.security.exceptions.XMLSecurityException;
-import org.apache.xml.security.stax.ext.XMLSecurityConstants;
 import org.w3c.dom.Document;
 import org.w3c.dom.Element;
 import org.w3c.dom.Node;
@@ -114,9 +112,11 @@ import org.apache.wss4j.policy.model.AlgorithmSuite;
 import org.apache.wss4j.policy.model.AlgorithmSuite.AlgorithmSuiteType;
 import org.apache.wss4j.policy.model.Trust10;
 import org.apache.wss4j.policy.model.Trust13;
+import org.apache.xml.security.exceptions.XMLSecurityException;
 import org.apache.xml.security.keys.content.X509Data;
 import org.apache.xml.security.keys.content.keyvalues.DSAKeyValue;
 import org.apache.xml.security.keys.content.keyvalues.RSAKeyValue;
+import org.apache.xml.security.stax.ext.XMLSecurityConstants;
 
 /**
  * A primitive STSClient for batch tokens. Note that this contains a number of hacks and should NOT be
diff --git a/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPublisher.java b/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPublisher.java
index 4617cc6d59..ae1fcaf21c 100644
--- a/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPublisher.java
+++ b/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPublisher.java
@@ -34,7 +34,6 @@ import jakarta.jms.Session;
 import jakarta.jms.Topic;
 import jakarta.xml.bind.JAXBContext;
 import jakarta.xml.bind.JAXBException;
-
 import org.apache.activemq.artemis.jms.client.ActiveMQTopic;
 import org.apache.cxf.common.logging.LogUtils;
 import org.apache.cxf.wsn.AbstractPublisher;
@@ -183,12 +182,10 @@ public abstract class JmsPublisher extends AbstractPublisher {
                 Object producer = producers.get(destination);
                 if ("CONSUMER_CREATED".equalsIgnoreCase(type)) {
                     final int consumerCount = event.getIntProperty("_AMQ_ConsumerCount");
-                    if (consumerCount > 0) {
-                        if (producer == null) {
-                            // start subscription
-                            producer = startSubscription(topic);
-                            producers.put(destination, producer);
-                        }
+                    if (consumerCount > 0 && producer == null) {
+                        // start subscription
+                        producer = startSubscription(topic);
+                        producers.put(destination, producer);
                     }
                 } else if ("CONSUMER_CLOSED".equalsIgnoreCase(type)) {
                     final int consumerCount = event.getIntProperty("_AMQ_ConsumerCount");
diff --git a/services/wsn/wsn-core/src/test/java/org/apache/cxf/wsn/WsnBrokerTest.java b/services/wsn/wsn-core/src/test/java/org/apache/cxf/wsn/WsnBrokerTest.java
index da5b98d8a3..607f0052ed 100644
--- a/services/wsn/wsn-core/src/test/java/org/apache/cxf/wsn/WsnBrokerTest.java
+++ b/services/wsn/wsn-core/src/test/java/org/apache/cxf/wsn/WsnBrokerTest.java
@@ -55,6 +55,7 @@ import org.apache.cxf.wsn.types.CustomType;
 import org.apache.cxf.wsn.util.WSNHelper;
 import org.oasis_open.docs.wsn.b_2.NotificationMessageHolderType;
 import org.oasis_open.docs.wsn.b_2.TopicExpressionType;
+
 import org.junit.After;
 import org.junit.Before;
 import org.junit.Test;
diff --git a/systests/container-integration/grizzly/src/test/java/org/apache/cxf/systest/grizzly/EndpointAPITest.java b/systests/container-integration/grizzly/src/test/java/org/apache/cxf/systest/grizzly/EndpointAPITest.java
index d2a05bc431..45381b5649 100644
--- a/systests/container-integration/grizzly/src/test/java/org/apache/cxf/systest/grizzly/EndpointAPITest.java
+++ b/systests/container-integration/grizzly/src/test/java/org/apache/cxf/systest/grizzly/EndpointAPITest.java
@@ -33,9 +33,9 @@ import jakarta.xml.ws.Service;
 import jakarta.xml.ws.soap.MTOMFeature;
 import jakarta.xml.ws.spi.http.HttpContext;
 import org.apache.cxf.testutil.common.TestUtil;
-
 import org.glassfish.grizzly.http.server.HttpServer;
 import org.glassfish.grizzly.http.server.NetworkListener;
+
 import org.junit.After;
 import org.junit.Before;
 import org.junit.Test;
diff --git a/systests/container-integration/grizzly/src/test/java/org/apache/cxf/systest/grizzly/GrizzlyHttpContext.java b/systests/container-integration/grizzly/src/test/java/org/apache/cxf/systest/grizzly/GrizzlyHttpContext.java
index b46972c340..71c0d02385 100644
--- a/systests/container-integration/grizzly/src/test/java/org/apache/cxf/systest/grizzly/GrizzlyHttpContext.java
+++ b/systests/container-integration/grizzly/src/test/java/org/apache/cxf/systest/grizzly/GrizzlyHttpContext.java
@@ -1,8 +1,27 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
 package org.apache.cxf.systest.grizzly;
 
-import jakarta.xml.ws.spi.http.HttpContext;
 import java.util.Map;
 import java.util.Set;
+
+import jakarta.xml.ws.spi.http.HttpContext;
 import org.glassfish.grizzly.http.server.HttpHandler;
 import org.glassfish.grizzly.http.server.HttpHandlerRegistration;
 import org.glassfish.grizzly.http.server.HttpServer;
@@ -22,9 +41,9 @@ public class GrizzlyHttpContext extends HttpContext {
     public void setHandler(jakarta.xml.ws.spi.http.HttpHandler handler) {
         HttpHandlerRegistration httpHandlerRegistration = new HttpHandlerRegistration.Builder().
                 contextPath(this.contextPath).urlPattern(path).build();
-        for (Map.Entry<HttpHandler, HttpHandlerRegistration[]> httpHandlerMapping :
-                server.getServerConfiguration().getHttpHandlersWithMapping().entrySet()) {
-            for(HttpHandlerRegistration registration : httpHandlerMapping.getValue()) {
+        for (Map.Entry<HttpHandler, HttpHandlerRegistration[]> httpHandlerMapping
+                : server.getServerConfiguration().getHttpHandlersWithMapping().entrySet()) {
+            for (HttpHandlerRegistration registration : httpHandlerMapping.getValue()) {
                 if (registration.equals(httpHandlerRegistration)) {
                     server.getServerConfiguration().removeHttpHandler(httpHandlerMapping.getKey());
                 }
diff --git a/systests/container-integration/grizzly/src/test/java/org/apache/cxf/systest/grizzly/GrizzlyHttpExchange.java b/systests/container-integration/grizzly/src/test/java/org/apache/cxf/systest/grizzly/GrizzlyHttpExchange.java
index 8bb77e28f2..2deb1c2995 100644
--- a/systests/container-integration/grizzly/src/test/java/org/apache/cxf/systest/grizzly/GrizzlyHttpExchange.java
+++ b/systests/container-integration/grizzly/src/test/java/org/apache/cxf/systest/grizzly/GrizzlyHttpExchange.java
@@ -1,7 +1,24 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
 package org.apache.cxf.systest.grizzly;
 
-import jakarta.xml.ws.spi.http.HttpContext;
-import jakarta.xml.ws.spi.http.HttpExchange;
+
 import java.io.IOException;
 import java.io.InputStream;
 import java.io.OutputStream;
@@ -12,6 +29,9 @@ import java.util.List;
 import java.util.Map;
 import java.util.Set;
 import java.util.TreeMap;
+
+import jakarta.xml.ws.spi.http.HttpContext;
+import jakarta.xml.ws.spi.http.HttpExchange;
 import org.glassfish.grizzly.http.server.Request;
 import org.glassfish.grizzly.http.server.Response;
 
diff --git a/systests/container-integration/grizzly/src/test/java/org/apache/cxf/systest/grizzly/GrizzlyHttpHandler.java b/systests/container-integration/grizzly/src/test/java/org/apache/cxf/systest/grizzly/GrizzlyHttpHandler.java
index db0d52df59..b082e8ba8a 100644
--- a/systests/container-integration/grizzly/src/test/java/org/apache/cxf/systest/grizzly/GrizzlyHttpHandler.java
+++ b/systests/container-integration/grizzly/src/test/java/org/apache/cxf/systest/grizzly/GrizzlyHttpHandler.java
@@ -1,3 +1,21 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
 package org.apache.cxf.systest.grizzly;
 
 import jakarta.xml.ws.spi.http.HttpHandler;
diff --git a/systests/transport-jms/src/test/java/org/apache/cxf/systest/jms/AbstractVmJMSTest.java b/systests/transport-jms/src/test/java/org/apache/cxf/systest/jms/AbstractVmJMSTest.java
index a99c4b778c..6a6e11df52 100644
--- a/systests/transport-jms/src/test/java/org/apache/cxf/systest/jms/AbstractVmJMSTest.java
+++ b/systests/transport-jms/src/test/java/org/apache/cxf/systest/jms/AbstractVmJMSTest.java
@@ -26,7 +26,6 @@ import java.util.List;
 
 import jakarta.jms.ConnectionFactory;
 import jakarta.xml.ws.Endpoint;
-
 import org.apache.activemq.artemis.api.core.SimpleString;
 import org.apache.activemq.artemis.core.config.Configuration;
 import org.apache.activemq.artemis.core.config.impl.ConfigurationImpl;