You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Claus Ibsen (JIRA)" <ji...@apache.org> on 2013/09/11 10:23:59 UTC
[jira] [Commented] (CAMEL-6720) SoapJaxbDataFormat not handling
correctly SOAP action with request wrapper element
[ https://issues.apache.org/jira/browse/CAMEL-6720?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13764111#comment-13764111 ]
Claus Ibsen commented on CAMEL-6720:
------------------------------------
An unit test to demonstrate this bug would be great. And as usual patches is welcome to fix this as well.
> SoapJaxbDataFormat not handling correctly SOAP action with request wrapper element
> ----------------------------------------------------------------------------------
>
> Key: CAMEL-6720
> URL: https://issues.apache.org/jira/browse/CAMEL-6720
> Project: Camel
> Issue Type: Bug
> Components: camel-soap
> Affects Versions: 2.12.0
> Reporter: Ondrej Fischer
> Priority: Minor
> Fix For: 2.12.1, 2.13.0
>
>
> If an interface to be used as SOAP service interface is configured to have parameters wrapped in a request wrapper element (eg. using @RequestWrapper),
> then an attempt to invoke a its method will throw NPE:
> {code}
> java.lang.NullPointerException
> at org.apache.camel.dataformat.soap.name.ServiceInterfaceStrategy.findQNameForSoapActionOrType(ServiceInterfaceStrategy.java:207)
> at org.apache.camel.dataformat.soap.SoapJaxbDataFormat.createContentFromObject(SoapJaxbDataFormat.java:208)
> at org.apache.camel.dataformat.soap.Soap11DataFormatAdapter.doMarshal(Soap11DataFormatAdapter.java:77)
> at org.apache.camel.dataformat.soap.SoapJaxbDataFormat.marshal(SoapJaxbDataFormat.java:141)
> at org.apache.camel.processor.MarshalProcessor.process(MarshalProcessor.java:59)
> {code}
> The reason for this is sequence of following:
> # The ServiceInterfaceStrategy is creating a mapping of methods to MethodInfo.
> # In case of RequestWrapper, the wrapper class is used as a single input TypeInfo, and no TypeInfo is being held for the real parameters.
> # At method invocation, it tries to lookup the TypeInfo in the MethodInfo, but for the real parameter class, and it only contains mapping for the request wrapper. So it fails with NPE.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira