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

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


The following commit(s) were added to refs/heads/main by this push:
     new ac12a540de93 fix(components): cxf javax leftover
ac12a540de93 is described below

commit ac12a540de934e44baa42eb1addef84cf627c253
Author: Pasquale Congiusti <[email protected]>
AuthorDate: Thu Dec 11 09:45:32 2025 +0100

    fix(components): cxf javax leftover
    
    Closes CAMEL-22769
---
 components/camel-cxf/camel-cxf-common/pom.xml                        | 5 +++++
 .../java/org/apache/camel/component/cxf/converter/CxfConverter.java  | 3 ++-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/components/camel-cxf/camel-cxf-common/pom.xml 
b/components/camel-cxf/camel-cxf-common/pom.xml
index 6cd01743f748..1ead63a8c67c 100644
--- a/components/camel-cxf/camel-cxf-common/pom.xml
+++ b/components/camel-cxf/camel-cxf-common/pom.xml
@@ -73,6 +73,11 @@
             <artifactId>jakarta.xml.soap-api</artifactId>
             <version>${jakarta-xml-soap-api-version}</version>
         </dependency>
+        <dependency>
+            <groupId>jakarta.xml.ws</groupId>
+            <artifactId>jakarta.xml.ws-api</artifactId>
+            <version>${jakarta-xml-ws-api-version}</version>
+        </dependency>
 
         <dependency>
             <groupId>org.apache.camel</groupId>
diff --git 
a/components/camel-cxf/camel-cxf-common/src/main/java/org/apache/camel/component/cxf/converter/CxfConverter.java
 
b/components/camel-cxf/camel-cxf-common/src/main/java/org/apache/camel/component/cxf/converter/CxfConverter.java
index ced53432b39e..d0bca9a7add8 100644
--- 
a/components/camel-cxf/camel-cxf-common/src/main/java/org/apache/camel/component/cxf/converter/CxfConverter.java
+++ 
b/components/camel-cxf/camel-cxf-common/src/main/java/org/apache/camel/component/cxf/converter/CxfConverter.java
@@ -23,6 +23,7 @@ import java.util.Collection;
 
 import jakarta.xml.soap.SOAPException;
 import jakarta.xml.soap.SOAPMessage;
+import jakarta.xml.ws.Holder;
 
 import javax.xml.namespace.QName;
 
@@ -137,7 +138,7 @@ public final class CxfConverter {
                 //If not, use the general way to convert from List.class to 
String.class
                 boolean foundHolder = false;
                 for (Object embedded : list) {
-                    if (embedded != null && 
embedded.getClass().getName().equals("javax.xml.ws.Holder")) {
+                    if (embedded != null && embedded instanceof Holder) {
                         foundHolder = true;
                         break;
                     }

Reply via email to