cancel
Showing results for 
Search instead for 
Did you mean: 

SOAP Fault Message

Former Member
0 Kudos

Hi,

Any idea what happens when receiver web service returns back fault message to XI..? After receiving this error, will XI return it back to sender service or it will throw an error from that point itself without sending it back to the sender system?

I have synchronous scenario of RFC -> XI -> Web service. When I pass proper parameters and call web service, response returned from web service is sent back to RFC properly. But, when I pass incorrect parameters, web service returns SOAP Fault message. Even though mapping is done for fault message to RFC Exception, error is directly shown in sxmb_moni. This is the error which web service returns as user id or password entered by me is wrong. RFC gives dump in this situation.

I am pasting that error below.

<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>

- <!-- Call Adapter

-->

- <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1">

<SAP:Category>XIAdapter</SAP:Category>

<SAP:Code area="PARSING">ADAPTER.SOAP_EXCEPTION</SAP:Code>

<SAP:P1 />

<SAP:P2 />

<SAP:P3 />

<SAP:P4 />

<SAP:AdditionalText>soap fault: com.ucas.hei.link.exception.WSException: Data access error: Incorrect userId/password. at com.ucas.hei.link.xml.ReferenceData.getRefInstUcas(ReferenceData.java:2338)</SAP:AdditionalText>

<SAP:ApplicationFaultMessage namespace="" />

<SAP:Stack />

<SAP:Retry>M</SAP:Retry>

</SAP:Error>

Can somebody help me to solve this problem?

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

hi,

even though you have a fault message defined, the error is not returned as a fault message, instead the fault message is raised as a exception to the caller.

from abap i am not aware of capturing the soap exception, it jsut gives you an rfc dump.

there is no elegant way to capture the exception from ABAP except for including your code in a standard try catch block or defining an exception for the rfc.

cheers,

naveen

Former Member
0 Kudos

Hi Naveen,

Thanks for the response. To be precise, I wanted to know, is there any way to get generated error id (faultcode), or text(faultstring) in RFC ? I am NOT using BPM.

Former Member
0 Kudos

Hi Smita,

BPM is not required (unless it is a Async-Sync scenario),

Ignore my msg, i got your question wrong

Regards

Vishnu

Former Member
0 Kudos

Hi Smita,

There may be a way to capture the exception in ABAP. I did try in an RFC but was not successful.

i shall try again and will update the post with my findings

cheers,

naveen

Former Member
0 Kudos

Hi Naveen,

Thank you!

At present, I call my RFC from ABAP program. As I have specified exception for RFC, it doesn't give dump. But, I don't get what error has occured at web service level. It will be very helpful for me if you can tell me how to capture fault code or fault text of fault SOAP message in ABAP program or in RFC itself.

Thanks again.

Best Regards,

-Smita

Former Member
0 Kudos

Hi there,

Did you finally resolve your issue?

I need to know how to include the exception info in the XI message payload itself too.

Best regards,

David