camel-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Daniel Fullarton (JIRA)" <>
Subject [jira] [Created] (CAMEL-11099) Unhandled ClassCastException if fault detail is not JaxbElement
Date Sun, 02 Apr 2017 23:59:41 GMT
Daniel Fullarton created CAMEL-11099:

             Summary: Unhandled ClassCastException if fault detail is not JaxbElement
                 Key: CAMEL-11099
             Project: Camel
          Issue Type: Bug
          Components: camel-soap
            Reporter: Daniel Fullarton
            Priority: Minor


I've been having some issues with handling some SOAP faults that come in with a detail message
that is undefined in their WSDL, the result is that they end up as xerces dom elements rather
than JAXBElements.

I end up with a pretty ugly message that looks like this : 
java.lang.ClassCastException: cannot
be cast to javax.xml.bind.JAXBElement
	at org.apache.camel.dataformat.soap.Soap11DataFormatAdapter.createExceptionFromFault(
	at org.apache.camel.dataformat.soap.Soap11DataFormatAdapter.doUnmarshal(
	at org.apache.camel.dataformat.soap.SoapJaxbDataFormat.unmarshal(
	at org.apache.camel.processor.UnmarshalProcessor.process(
	at org.apache.camel.processor.RedeliveryErrorHandler.process(
	at org.apache.camel.processor.CamelInternalProcessor.process(

It's pretty had to intercept this in the pipeline, so at the moment I've handled parsing the
response myself rather than the soap dataformat, but I would like to avoid this in the future
as it does require a bit of custom code.

I'll create a PR that demonstrates what I believe is a reasonable workaround.


This message was sent by Atlassian JIRA

View raw message