camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From james555 <>
Subject Re: JAXB-Unmarshalling of soap xml including schema validation
Date Wed, 21 May 2014 07:49:14 GMT

Hi Willem,

a little bit confusing, but now I got it. In my code I used "import
org.apache.camel.model.dataformat.SoapJaxbDataFormat;" where setSchema is an
invalid method. Compared with your testcase "import
org.apache.camel.dataformat.soap.SoapJaxbDataFormat;" with setSchema method
is used, thanks !

Sideeffect of the two existing SoapJaxbDataFormat classes:
I define my SoapJaxbDataFormat in a servlet scenario with a
CamelContextLifecycle. Since
"org.apache.camel.dataformat.soap.SoapJaxbDataFormat" is not a
"DataFormatDefinition" I can't use

camelContext.getDataFormats().put("soapJaxbDataFormat", soapJaxbDataFormat);

to access the SoapJaxbDataFormat in a RouteBuilder comfortably (Compiler
says: "The method put(String, DataFormatDefinition) in the type
Map<String,DataFormatDefinition> is not applicable for the arguments
(String, SoapJaxbDataFormat)". Is that meant to be ? As a workaround I now
have to use the Registry with bean binding: 

registry.bind("soapJaxbDataFormat", soapJaxbDataFormat);

Is there a better way to access SoapJaxbDataFormat ?

	big thanks !


View this message in context:
Sent from the Camel - Users mailing list archive at

View raw message