on ‎2010 Oct 22 1:23 PM
Hi,
I guess these are two questions.
We are implementing a webservice from a provider. The WSDL is RPC-style. We could import it in PI and generate the proxies in ABAP. The requests are properly sent to the provider but we have problems with the returning message.
Line: -
When the response is positive, we get a parsing problem. Executing the service in SoapUI, this is the returning message:
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
<SOAP-ENV:Body>
<SOAP-ENV:loginResponse>
<Result>s4vep9dm4iu1teh877cdduk0e1</Result>
</SOAP-ENV:loginResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>When testing in SPROXY, this is the result (without the soap body):
- <SOAP-ENV:loginResponse xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
<Result>0s5bbett500h183v7fi32jm2o3</Result>
</SOAP-ENV:loginResponse>We get the following error message from the parser: Element 'loginResponse' expected. Should the 'loginResponse' tag refer to another namespace? Does this mean the provider's respons is wrong?
Line: -
When the response is negative, we get the following response (as seen in SoapUI):
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
<SOAP-ENV:Body>
<SOAP-ENV:Fault>
<faultcode>0001</faultcode>
<faultstring>Invalid account credentials.</faultstring>
</SOAP-ENV:Fault>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>This is the error we see when we test in SPROXY:
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
- <!-- Inbound Message
-->
- <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1">
<SAP:Category>XIAdapterFramework</SAP:Category>
<SAP:Code area="MESSAGE">GENERAL</SAP:Code>
<SAP:P1 />
<SAP:P2 />
<SAP:P3 />
<SAP:P4 />
<SAP:AdditionalText>com.sap.engine.interfaces.messaging.api.exception.MessagingException: SOAP: response message contains an error XIAdapter/PARSING/ADAPTER.SOAP_EXCEPTION - soap fault: Invalid account credentials.</SAP:AdditionalText>
<SAP:Stack />
<SAP:Retry>M</SAP:Retry>
</SAP:Error>
In order to be able to catch this standard soap fault, we took a look at this blog:/people/jin.shin/blog/2007/05/21/handling-web-service-soap-fault-responses-in-sap-netweaver-xi
It guided us through the fault mapping, but still we don't get the correct respons. Are there some supplementary settings we have to pay attention to?
Thanks for any help.
Kris
Request clarification before answering.
> We get the following error message from the parser: Element 'loginResponse' expected. Should the 'loginResponse' tag refer to another namespace?
> Does this mean the provider's respons is wrong?
Yes, indeed. The namespace "http://schemas.xmlsoap.org/soap/envelope/" must not be used for SOAP body elements.
Here the webservice has to be changed.
> In order to be able to catch this standard soap fault, we took a look at this blog:/people/jin.shin/blog/2007/05/21/handling-web-service-soap-fault-responses-in-sap-netweaver-xi
> It guided us through the fault mapping, but still we don't get the correct respons. Are there some supplementary settings we have to pay attention to?
I think the SOAP adapter changes the application fault into a system fault. So you should have the response in the system fault exception in ABAP proxy.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
> The wsdl from out provider does not mention any fault handling. Could that be the reason?
The SOAP adapter does not read or interpret the WSDL at runtime.
I have not much experience with this topic, but I suppose that the SOAP adapter simply does not create an application fault from a SOAP response, but a system fault instead. I have no idea how this can be prevented.
| User | Count |
|---|---|
| 13 | |
| 8 | |
| 7 | |
| 5 | |
| 4 | |
| 3 | |
| 2 | |
| 2 | |
| 2 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.