Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Handling standard SOAP fault in Proxy to SOAP synchronous scenario

Hi Gurus,

Hope you are doing well.

I have a synchronous Proxy to SOAP (Web Service) scenario in SAP PI 7.0 environment. Here we are consuming an external web service in PI. The web service is a standard one and consists of a number of methods for handling different functions such as create, query, update and delete. I have defined request structures for sending requests using corresponding methods defined in the external web service and the same are working fine. I have also defined response structures for receiving responses using corresponding methods defined in the the external web service and the same are also working fine. The problem is the external web service does not have any method defined for sending fault messages. The fault message being returned is a standard SOAP fault having the following structure. Since there is no method defined in the external web service, the SOAP message returned back is not getting caught in PI and is being treated as a system error.

<env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:f="http://www.w3.org/2001/12/soap-faults">
<env:Body>
  <env:Fault>
  <faultcode>env:Sender</faultcode>
  <faultstring>XXXXXXXX</faultstring>
  <detail>
  <Error>
    <Code>XX</Code>
    <Description>XXXXXXXXXX</Description>
    <Path>XXXXXXXX</Path>
  </Error>
  <Error>
  <Code>XX</Code>
    <Description>XXXXXXXXXX</Description>
    <Path>XXXXXXXX</Path>
  </Error>
  .....
  .....
  </detail>
  </env:Fault>
</env:Body>
</env:Envelope>

I tried defining a similar structure withion the external WSDL and mapping the same to XI fault structure but still the exception did not get caught. I also tried defining the above fault structure as part of the response but still the exception did not get caught.

Is there a way to catch the fault in PI? Please let me know. Points would be assigned to helpful answers.

regards
Debansu

Former Member

Helpful Answer

by
Not what you were looking for? View more on this topic or Ask a question