git.net

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Camel cxf: Send message with multiple message-parts


Hi everyone,

 

no ideas regarding this problem?

 

I add a small example project to this mail. In order to reproduce the problem, start Server.java as a junit-Test. After that, start the Client.java as junit-test as well. (In client_beans_reproduce.xml line 44, you can change the payload to try different payload along with the request) You will see the following error message:

The PayLoad elements cannot fit with the message parts of the BindingOperation. Please check the BindingOperation and PayLoadMessage.

 

My question is: How to provide the payload in order to be able to send the request. Any ideas/help to fix this problem is much appreciated.

 

Thanks in advance.

Best regards,

Manuel

 

From: Shenavai, Manuel
Sent: Freitag, 16. März 2018 11:49
To: 'users-subscribe@xxxxxxxxxxxxxxxx' <users-subscribe@xxxxxxxxxxxxxxxx>
Subject: Camel cxf: Send message with multiple message-parts

 

Hi everyone,

 

I try to send a message with camel-cxf to a WS provider. When trying to send the message with multiple message-parts defined in the WSDL, the following error is thrown (see below). My question is: How the payload has to be provided in this case? Please let me know if I should provide any more infos.

 

The endpoint is using dataFormat=PAYLOAD.

 

Thanks in advance

Best regards,

Manuel

 

------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

Camel-Body:

< manuel_operation>

   <first_name>?</ first_name >

   <last_name>?</ fast_name >

</manuel_operation>

 

Error:

java.lang.IllegalArgumentException: The PayLoad elements cannot fit with the message parts of the BindingOperation. Please check the BindingOperation and PayLoadMessage.

------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

Camel-Body:

   <first_name>?</ first_name >

   <last_name>?</ fast_name >

 

Error:

org.apache.cxf.interceptor.Fault: Could not generate the XML stream caused by: com.ctc.wstx.exc.WstxParsingException: Illegal to have multiple roots (start tag in epilog?).

at [row,col {unknown-source}]: [1,65]., cause: com.ctc.wstx.exc.WstxParsingException: Illegal to have multiple roots (start tag in epilog?).

at [row,col {unknown-source}]: [1,65]

------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

 

 

More infos

Parts of WSDL:

<wsdl:message name="manuel_operationRequest">

                <wsdl:part name="first_name"/>

                <wsdl:part name="fast_name"/>

</wsdl:message>

 

 

<wsdl:binding name="manuel.cfcSoapBinding" type="impl:manuel">

                <wsdlsoap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>

                <wsdl:operation name="manuel_operation">

                               <wsdlsoap:operation soapAction=""/>

                              

                               <wsdl:input name="manuel_operationRequest"></wsdl:input>

 

                               ….

 

                </wsdl:operation>

</wsdl:binding>

Attachment: example.zip
Description: example.zip



( ! ) Warning: include(msgfooter.php): failed to open stream: No such file or directory in /var/www/git/apache-camel-users/msg03159.html on line 154
Call Stack
#TimeMemoryFunctionLocation
10.0009372792{main}( ).../msg03159.html:0

( ! ) Warning: include(): Failed opening 'msgfooter.php' for inclusion (include_path='.:/var/www/git') in /var/www/git/apache-camel-users/msg03159.html on line 154
Call Stack
#TimeMemoryFunctionLocation
10.0009372792{main}( ).../msg03159.html:0