camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mario Fusco <mario.fu...@gmail.com>
Subject ClassCastException marshalling cxf message
Date Thu, 09 Jan 2014 09:50:49 GMT
Hi, 

I am one of the core developer of Drools and I am trying to debug and fix a
problem reported by one of our user in this email
http://drools.46999.n3.nabble.com/Drools-6-0-1-xstream-marshaling-via-camel-config-not-working-td4027607.html

I can reproduce the issue he reported, but not being a Camel expert I am not
100% sure that what he is trying to do is correct. Anyway when running his
example I obtain the same ClassCastException he reported:

java.lang.ClassCastException: java.util.ArrayList cannot be cast to
org.apache.cxf.message.MessageContentsList
	at
org.apache.camel.component.cxf.jaxrs.DefaultCxfRsBinding.bindCamelMessageBodyToRequestBody(DefaultCxfRsBinding.java:166)
~[camel-cxf-2.10.3.jar:2.10.3]
	at
org.apache.camel.component.cxf.jaxrs.CxfRsProducer.invokeHttpClient(CxfRsProducer.java:143)
~[camel-cxf-2.10.3.jar:2.10.3]
	at
org.apache.camel.component.cxf.jaxrs.CxfRsProducer.process(CxfRsProducer.java:87)
~[camel-cxf-2.10.3.jar:2.10.3]

The fact that explicitly doing the marshaling in the java client fixes the
problem ( together with what reported in this other email
http://camel.465427.n5.nabble.com/CXFRS-Producer-td5722162.html ) makes me
think that this issue could be possibly caused by an incompatibility between
the versions of camel and cxf we are using. However looking at our
dependencies I couldn't find an evidence of this. I am pasting below our
complete dependency tree in case this could help to find the problem.

However I cannot exclude that I am completely on the wrong path and the
cause of this problem could be somewhere else, so any suggestion to fix this
issue will be very appreciated.

Thanks and regards,
Mario


[INFO] --- maven-dependency-plugin:2.8:tree (default-cli) @ kie-camel 
[INFO] +- org.drools:drools-core:jar:6.1.0-SNAPSHOT:compile
[INFO] |  \- org.mvel:mvel2:jar:2.1.8.Final:compile
[INFO] +- org.drools:drools-compiler:jar:6.1.0-SNAPSHOT:compile
[INFO] |  +- org.antlr:antlr-runtime:jar:3.5:compile
[INFO] |  +- org.eclipse.jdt.core.compiler:ecj:jar:3.7.2:compile
[INFO] |  +- com.thoughtworks.xstream:xstream:jar:1.4.3:compile
[INFO] |  |  +- xmlpull:xmlpull:jar:1.1.3.1:compile
[INFO] |  |  \- xpp3:xpp3_min:jar:1.1.4c:compile
[INFO] |  \- com.google.protobuf:protobuf-java:jar:2.5.0:compile
[INFO] +- org.jbpm:jbpm-flow-builder:jar:6.1.0-SNAPSHOT:compile
[INFO] |  \- org.jbpm:jbpm-flow:jar:6.1.0-SNAPSHOT:compile
[INFO] |     \- joda-time:joda-time:jar:1.6.2:compile
[INFO] +- org.kie:kie-spring:jar:6.1.0-SNAPSHOT:compile
[INFO] |  +- org.drools:drools-decisiontables:jar:6.1.0-SNAPSHOT:compile
[INFO] |  |  +- org.drools:drools-templates:jar:6.1.0-SNAPSHOT:compile
[INFO] |  |  \- org.apache.poi:poi-ooxml:jar:3.9:compile
[INFO] |  |     +- org.apache.poi:poi:jar:3.9:compile
[INFO] |  |     +- org.apache.poi:poi-ooxml-schemas:jar:3.9:compile
[INFO] |  |     |  \- org.apache.xmlbeans:xmlbeans:jar:2.3.0:compile
[INFO] |  |     \- dom4j:dom4j:jar:1.6.1:compile
[INFO] |  |        \- xml-apis:xml-apis:jar:1.3.04:compile
[INFO] |  +- org.springframework:spring-beans:jar:3.0.7.RELEASE:compile
[INFO] |  +- org.springframework:spring-context:jar:3.0.7.RELEASE:compile
[INFO] |  |  \-
org.springframework:spring-expression:jar:3.0.7.RELEASE:compile
[INFO] |  +- org.jboss.seam.spring:seam-spring-core:jar:3.1.0.Final:compile
[INFO] |  |  +-
org.springframework:spring-context-support:jar:3.0.6.RELEASE:compile
[INFO] |  |  \- org.springframework:spring-web:jar:3.0.7.RELEASE:compile
[INFO] |  +- javax.enterprise:cdi-api:jar:1.0-SP4:compile
[INFO] |  |  +-
org.jboss.spec.javax.interceptor:jboss-interceptors-api_1.1_spec:jar:1.0.0.Beta1:compile
[INFO] |  |  +- javax.annotation:jsr250-api:jar:1.0:compile
[INFO] |  |  \- javax.inject:javax.inject:jar:1:compile
[INFO] |  \- org.jboss.weld.se:weld-se-core:jar:1.1.13.Final:compile
[INFO] |     +- org.jboss.weld:weld-spi:jar:1.1.Final:compile
[INFO] |     |  \- org.jboss.weld:weld-api:jar:1.1.Final:compile
[INFO] |     +- org.jboss.weld:weld-core:jar:1.1.13.Final:compile
[INFO] |     |  +- org.javassist:javassist:jar:3.15.0-GA:compile
[INFO] |     |  +- com.google.guava:guava:jar:13.0.1:compile
[INFO] |     |  +- org.slf4j:slf4j-ext:jar:1.7.2:compile
[INFO] |     |  \- ch.qos.cal10n:cal10n-api:jar:0.7.4:compile
[INFO] |     \- javax.el:el-api:jar:2.2:compile
[INFO] +- org.apache.camel:camel-core:jar:2.10.3:compile
[INFO] +- org.apache.camel:camel-spring:jar:2.10.3:compile
[INFO] |  \- org.springframework:spring-tx:jar:3.0.7.RELEASE:compile
[INFO] +- org.apache.camel:camel-cxf:jar:2.10.3:compile
[INFO] |  +- org.apache.camel:camel-cxf-transport:jar:2.10.3:compile
[INFO] |  +- org.apache.cxf:cxf-rt-frontend-jaxrs:jar:2.6.8:compile
[INFO] |  +- org.apache.camel:camel-blueprint:jar:2.10.3:compile
[INFO] |  |  +- org.apache.camel:camel-core-xml:jar:2.10.3:compile
[INFO] |  |  \- org.apache.camel:camel-core-osgi:jar:2.10.3:compile
[INFO] |  +-
org.apache.aries.blueprint:org.apache.aries.blueprint:jar:0.3:compile
[INFO] |  |  +- org.apache.aries:org.apache.aries.util:jar:0.3:compile
[INFO] |  |  +-
org.apache.aries.testsupport:org.apache.aries.testsupport.unit:jar:0.3:compile
[INFO] |  |  \-
org.apache.aries.proxy:org.apache.aries.proxy.api:jar:0.3:compile
[INFO] |  \- org.apache.cxf:cxf-rt-bindings-soap:jar:2.6.3:compile
[INFO] |     \- org.apache.cxf:cxf-rt-databinding-jaxb:jar:2.6.8:compile
[INFO] +- org.apache.camel:camel-xstream:jar:2.10.3:compile
[INFO] |  +- stax:stax-api:jar:1.0.1:compile
[INFO] |  +- org.codehaus.jettison:jettison:jar:1.3.1:compile
[INFO] |  \- org.codehaus.woodstox:woodstox-core-asl:jar:4.2.0:compile
[INFO] +- org.apache.camel:camel-jaxb:jar:2.10.3:compile
[INFO] +- org.apache.camel:camel-test:jar:2.10.3:test
[INFO] +- org.apache.camel:camel-test-spring:jar:2.10.3:test
[INFO] +- org.springframework:spring-core:jar:3.0.7.RELEASE:compile
[INFO] |  +- org.springframework:spring-asm:jar:3.0.7.RELEASE:compile
[INFO] |  \- commons-logging:commons-logging:jar:1.1.1:compile
[INFO] +- org.springframework:spring-aop:jar:3.0.7.RELEASE:compile
[INFO] |  \- aopalliance:aopalliance:jar:1.0:compile
[INFO] +- org.springframework:spring-test:jar:3.0.7.RELEASE:test
[INFO] +- org.apache.cxf:cxf-rt-frontend-jaxws:jar:2.6.8:compile
[INFO] |  +- xml-resolver:xml-resolver:jar:1.2:compile
[INFO] |  +- asm:asm:jar:3.1:compile
[INFO] |  +- org.apache.cxf:cxf-api:jar:2.6.8:compile
[INFO] |  +- org.apache.cxf:cxf-rt-core:jar:2.6.8:compile
[INFO] |  +- org.apache.cxf:cxf-rt-bindings-xml:jar:2.6.8:compile
[INFO] |  +- org.apache.cxf:cxf-rt-frontend-simple:jar:2.6.8:compile
[INFO] |  +- org.apache.cxf:cxf-rt-transports-http:jar:2.6.8:compile
[INFO] |  \- org.apache.cxf:cxf-rt-ws-addr:jar:2.6.8:compile
[INFO] |     \- org.apache.cxf:cxf-rt-ws-policy:jar:2.6.8:compile
[INFO] |        \- org.apache.neethi:neethi:jar:3.0.2:compile
[INFO] +- org.apache.cxf:cxf-bundle-jaxrs:jar:2.6.8:compile
[INFO] |  +- org.codehaus.woodstox:stax2-api:jar:3.1.1:compile
[INFO] |  +- org.apache.ws.xmlschema:xmlschema-core:jar:2.0.3:compile
[INFO] |  +-
org.apache.geronimo.specs:geronimo-javamail_1.4_spec:jar:1.7.1:compile
[INFO] |  +- wsdl4j:wsdl4j:jar:1.6.2:compile
[INFO] |  +-
org.apache.geronimo.specs:geronimo-stax-api_1.0_spec:jar:1.0.1:compile
[INFO] |  +- javax.xml.bind:jaxb-api:jar:2.2.5:compile
[INFO] |  +-
org.apache.geronimo.specs:geronimo-activation_1.1_spec:jar:1.1:compile
[INFO] |  +-
org.apache.geronimo.specs:geronimo-annotation_1.0_spec:jar:1.1.1:compile
[INFO] |  +- org.eclipse.jetty:jetty-server:jar:7.5.4.v20111024:compile
[INFO] |  +-
org.eclipse.jetty:jetty-continuation:jar:7.5.4.v20111024:compile
[INFO] |  +- org.eclipse.jetty:jetty-http:jar:7.5.4.v20111024:compile
[INFO] |  +- org.eclipse.jetty:jetty-io:jar:7.5.4.v20111024:compile
[INFO] |  +- org.eclipse.jetty:jetty-util:jar:7.5.4.v20111024:compile
[INFO] |  +- org.eclipse.jetty:jetty-security:jar:7.5.4.v20111024:compile
[INFO] |  \- javax.ws.rs:jsr311-api:jar:1.1.1:compile
[INFO] +- commons-httpclient:commons-httpclient:jar:3.1:test
[INFO] |  \- commons-codec:commons-codec:jar:1.4:compile
[INFO] +- com.sun.xml.bind:jaxb-impl:jar:2.2.5:compile
[INFO] +- com.sun.xml.bind:jaxb-xjc:jar:2.2.5:compile
[INFO] +- xmlunit:xmlunit:jar:1.3:test
[INFO] +- org.slf4j:slf4j-api:jar:1.7.2:compile
[INFO] +- ch.qos.logback:logback-classic:jar:1.0.9:test
[INFO] |  \- ch.qos.logback:logback-core:jar:1.0.9:test
[INFO] +- org.codehaus.jackson:jackson-core-asl:jar:1.9.9:test
[INFO] +- org.codehaus.jackson:jackson-mapper-asl:jar:1.9.9:test
[INFO] +-
org.jboss.spec.javax.servlet:jboss-servlet-api_3.0_spec:jar:1.0.2.Final:provided
[INFO] +- junit:junit:jar:4.11:test
[INFO] |  \- org.hamcrest:hamcrest-core:jar:1.3:test
[INFO] \- org.mockito:mockito-all:jar:1.9.0:test




--
View this message in context: http://camel.465427.n5.nabble.com/ClassCastException-marshalling-cxf-message-tp5745777.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Mime
View raw message