cancel
Showing results for 
Search instead for 
Did you mean: 

SOAP call failed in PI but works in SOAP UI and XMLSpy

Former Member
0 Kudos

Dear all,

Facing an issue in PI while calling one of the HP  service.

IDOCS-->SAP PI -->SOAP Adapter --> HP web service ( Not handling the response from web service)

I am just expecting HTTP 500 in case of error and HTTP 200 incase of successful webservice call ( Default SOAP receiver adapter behavior)

I am getting HTTP 500 Error in receiver CC but SOAP request with the same payload ( from MDT) SOAP message works fine in SOAP UI and XML Spy and i got the successful response  (i.e) HTTP 200 along with . So there should be not any issues with the input data or SOAP structure or Authentication ( FYI:  I am using Token authentication in the SOAP header using XSLT mapping  and populating my entire SOAP message in XSLT mapping )

What i tried

  • No Network issues between SAP PI box and Web server . 8080 port is also open so should not be any infrastructure issues. Correct me if i am wrong
  • No useful log information at the web server side.
  • Content-Type was sent to Content-Type: text/xml;charset=UTF-8.
  • Message Protocol is SOAP 1.1
  • Tried with ignoreSOAPStatus bean in the receiver communication channel to ignore the responses. Result : in PI it is succesful but no entries in webservice.

What could be the issue here?

PS: The request reach web server as i can see SAP PI IP address in the web server log file .

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi all,

I have managed to solve the issue finally

Thanks for all for your valid inputs.

Issue: Validated the SOAP request ( after PI mapping ) with WSDL using Altova XML spy and found out an issue with one of the XML tag. Typo issue

Answers (4)

Answers (4)

iaki_vila
Active Contributor
0 Kudos

Hi Rajesh,

( FYI:  I am using Token authentication in the SOAP header using XSLT mapping  and populating my entire SOAP message in XSLT mapping )

If you are modifying the SOAP header in the XSL mapping, you should choose the option "Do no use SOAP envelope" in the SOAP receiver communication channel, are you?

Are you using ws-security?

Regards

Former Member
0 Kudos

Yes. I do have option DO not use SOAP envolope as I send entire message from XSLT mapping.. I also checked without this option (i.e) sending Standard SOAP evlope from SOAP adapter. It throws clear error message in CC itself (i.e) Security missing.

I am just using the SOAP header as per the web service guidelien document from HP.

<soap:Header>

<wsse:Security xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" soap:mustUnderstand="1">

<wsse:UsernameToken xmlns:wsu="http://docs.oasisopen.org/wss/2004/01/oasis-200401-wss-wssecurityutility-1.0.xsd" wsu:Id="UsernameToken-7433399">

<wsse:Username>UserName</wsse:Username>

<wsse:Password Type="passwordhttp://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordT...>

</wsse:UsernameToken>

</wsse:Security>

</soap:Header>

markangelo_dihiansan
Active Contributor
0 Kudos

Hello,

SOAP UI and Altova also supports SOAP 1.2, HTTP GET, RPC-Encoded WSDLs. To rule this out, can you paste the data from the raw tab for the request just after you have executed it? e.g

Regards,

Mark

Former Member
0 Kudos

Hi Mark,

PFB. It supports SOAP 1.1

Ryan-Crosby
Active Contributor
0 Kudos

Hi Rajesh,

So many times I have seen the same problem with the designation elementFormDefault="qualified" in the WSDL for a web service.  By default XI/PI does not insert the namespace designations in the XML and I know this happened the first time I had to build an interface to an external web service.  I would definitely look for this because it was the same behavior (works in soapUI but not in PI).  If that is the case you can import the WSDL as an external definition and then mirror the message in an internal designation and do a 1:1 graphical mapping to solve the problem.

Regards,

Ryan Crosby

baskar_gopalakrishnan2
Active Contributor
0 Kudos

Few cents...

a) Check your target URL in the communication channel. Is this valid ? Also you can open wsdl and look for location tag and see the url.

b) I suspect problem might be due to XSLT mapping. After your mapping the message header might have some issues for the webservice server to accept it. Check namespace declaration etc are matching with the target system specification. This could also cause http 500 error.

c) Do you have action for this service? if so specify in the action field of the communication channel.

d) capture the message that comes after mapping step in the sxmb_moni and show it to the target system and see whether any problem in the soap header due to XSLT mapping.

Hope that helps.

Former Member
0 Kudos

@ Bhaskar

a) Check your target URL in the communication channel. Is this valid ? Also you can open wsdl and look for location tag and see the url.

        Yes. It is valid. I copied from WSDL only

b) I suspect problem might be due to XSLT mapping. After your mapping the message header might have some issues for the webservice server to accept it. Check namespace declaration etc are matching with the target system specification. This could also cause http 500 error.

d) capture the message that comes after mapping step in the sxmb_moni and show it to the target system and see whether any problem in the soap header due to XSLT mapping.

    Namespaces are correct .if is not correct, it would throw the error message in SOAP UI iteslef.

As I mentioned earlier, i copied the mapping output from MDT and sent from SOAP UI. so there would not be any issues with Mapping or Namespace definitions. But i will cross check them once again

c) Do you have action for this service? if so specify in the action field of the communication channel.

  Yes. I do. I already updated in the channel

@Ryan

Let me try that as well.