cancel
Showing results for 
Search instead for 
Did you mean: 

Failure SOAP sync scenario - receiving response message

04-26-2012 11:41 AM
2665 views 14 comments Go to solution
0 Likes
SAP Managed Tags
Subscribe

Hi,

i facing a problem with the pi soap adapter. i want to send am message with connection credentials to a soap webservice and then use the ID from the response for the following transactions/messages (it´s like a stateful soap scenario: connect web service, connect port, do things, release port, release web service)

To create the request i am using a xsl mapping and activated in the receiver soap channel the "do not use soap envelope" and "keep header data"

also i set in modules soap     XMBWS.NoSOAPIgnoreStatusCode      true

the problem is that i am not getting the response message back. i see a finished flag for the request message in sxmb_moni but in the channel monitoring ther is the following error

When i test the call with the payload from xsl mapping in soap ui i am getting a successful response. The ? i used for anonymization

HTTP/1.1 200 OK

Date: Thu, 26 Apr 2012 08:24:29 GMT

Server: Apache/2.2.14 (Win32) mod_ssl/2.2.14 OpenSSL/0.9.8k mod_jk/1.2.31

Content-Length: 805

Keep-Alive: timeout=5, max=100

Connection: Keep-Alive

Content-Type: text/xml;charset=utf-8

<?xml version='1.0' encoding='UTF-8'?>

<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<SOAP-ENV:Header>

<t:wsID xmlns:t="???????/???????" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"><UUID xsi:type="xsd:string">THE ID I NEED</UUID></t:wsID>

</SOAP-ENV:Header>

<SOAP-ENV:Body>

<ns1:Connect_ws?????? xmlns:ns1="???????e/???????" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">

</ns1:Connect_Response>

</SOAP-ENV:Body>

</SOAP-ENV:Envelope>

Could you please advise

many thanks

Michael

0 Likes

Accepted Solutions (1)

Accepted Solutions (1)

markangelo_dihiansan
Active Contributor
0 Likes

Hello Michael,

Question: 1. Is your sender/receiver service interface set as synchronous?

2. The target webservice is using RPC-encoding as specified by

encodingStyle="http://schemas.xmlsoap.org/soap/encoding/", are you sure that you do not need a SOAP Action in your CC?

Since you have checked the Do Not Use SOAP Envelope option, the content-type gets transformed to application/xml. To use the text/xml content type, use the MessageTransformBean in your SOAP Receiver CC.

Hope this helps,

Mark

Former Member
0 Likes

Hi Mark,

many thanks for your reply

1. both sender and receiver service interfaces are set to synchronous

2. i updated the channel

also i added the module

then i use the message for request from the wsdl and mapped my credentials

The error i am now getting is the following

fo addition in soap ui the request looks like this

<soapenv:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsk="????????/????????????">

   <soapenv:Header/>

   <soapenv:Body>

      <wsk:SOAP-ACTION? soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">

         <userId xsi:type="xsd:string">??</userId>

         <password xsi:type="xsd:string">??</password>

         <appServerInfo xsi:type="xsd:string">???</appServerInfo>

      </wsk:SOAP-ACTION?>

   </soapenv:Body>

</soapenv:Envelope>

markangelo_dihiansan
Active Contributor
0 Likes

Hello Michael,

Your target URL seems incorrect and the Do Not Use SOAP Envelope should be checked since you are building it using XSLT. Here is a sample calculator Webservice:

http://www.html2xml.nl/Services/Calculator/Version1/Calculator.asmx?op=Add

See the specifications:

For example, in the calculator webservice, the SOAP Receiver CC settings should be:

The correct Target URL is: www.html2xml.nl/Services/Calculator/Version1/Calculator.asmx

SOAP Action is: http://tempuri.org/Add

I think you are getting the 404 error because you are posting in an Operation service description URL. With regards to the calculator webservice, the URL for the service description for addition is:

http://www.html2xml.nl/Services/Calculator/Version1/Calculator.asmx?op=Add

Hope this helps,

Mark

Former Member
0 Likes

Hi Angelo,

thanks for your reply.

The WebService provider also doc/literal, i imported the wsdl for testing and found it might better match the requirements (e.g. i got the connect.response message)

What is better? rpc oder doc?

I checked the wsdl rpc and doc and found no soap action. the entry for the soap action looks like this

<soap:operation soapAction="" style="document" />

when i test the scenario with the new message types and change cc (uncheck do not use soap envelope, leave action blank and use the url i used in my soap ui test)

i got the following error message. Might there be a communication error in our network (firewall...)?

markangelo_dihiansan
Active Contributor
0 Likes

Hello Michael,

Without any modifications to the SOAP Receiver CC, it would only accept Document-Literal SOAP 1.1 Webservices. For the no response error, can you check in sxi_monitor?

Regards,

Mark

Former Member
0 Likes

Hi Mark,

in sxi_moni i don´t see any message (no response and request)

best regards,

Michael

markangelo_dihiansan
Active Contributor
0 Likes

Hello Michael,

That is probably because LOGGING_SYNC is turned off in your XI system. To check this, go to SXMB_ADM -> Integration Engine Configuration -> F9

Hope this helps,

Mark

Answers (2)

Answers (2)

Former Member
0 Likes

This Prob with Adapter framework after restarting the PI System it might get resolved i had faced similar problem with JDBC adapter.

Better to check with Basis team to investigate further.I hope your target system  is up and running.

Former Member
0 Likes

Hi Michael,

It looks like a problem for PI to connect to the web service. Make sure of the following:

1. Can PI connect to the target system, over the Proxy server you defined in the receiver CC (in terms of network connectivity)?

2. Is the Target URL correct?

3. Don't you need to use SOAP Action?

For 2 and 3, compare the settings to what is used by SOAP UI.

Hope this helps,

Greg

Former Member
0 Likes

Hi Greg,

many thanks for your reply.

As written above i updated the connection parameters.

1. I am not sure. I am running another scenario calling via proxy a http adress (another pi system). This works.

What i realy not understand is that in messagemonitoring sxmb_moni i am not getting any response message

as said with soap ui everything is fine

baskar_gopalakrishnan2
Active Contributor
0 Likes

I think your communication channel is set for EO or EOIO. Please check that ... though you might have corrected the service interface to sync mode.  Also you first screenshot shows at the end...

Message monitoring shows:  Asynchronous message is at the delivered status.  So that's the reason you dont see the response. Check your communication channels.

Former Member
0 Likes

Hi Michael,

Some questions I have to your before I trace your issue and provide help.

  • Does the recipient or the target webserver is open to the IP address/es of your PI server. In short, Is firewall rule created in their end for your server?
  • From your xsl mapping and you did test it using SOAP UI, you mentioned that you did get a response, so you did configure your Service Interface as Synchronous. Have you considered your operation mapping on request and response part of the configuration?
  • Was the external definition of wsdl provided to you by the party or you developed it down to up?

Cheers,

R-jay

Former Member
0 Likes

Hi R-jay,

i have tested the connection calls with the pi and soap ui. in both cases the request was sent correct to the webservice.

The problem i am now facing is that i see no response message in pi.

i see the request message with final flag in monitoring and also the response message with final flag in monitoring.

When i want to open the response message i am getting this error

in nwa log i found

and on top this message

i also scipped the xsl mapping and use the adapter without activating the "do not use soap envelope" option.

when i test the scenario with soap ui i am getting a response

in raw it looks like this

HTTP/1.1 200 OK

Date: Thu, 03 May 2012 12:04:55 GMT

Server: Apache/2.2.14 (Win32) mod_ssl/2.2.14 OpenSSL/0.9.8k mod_jk/1.2.31

Content-Length: 631

Keep-Alive: timeout=5, max=100

Connection: Keep-Alive

Content-Type: text/xml;charset=utf-8

<?xml version='1.0' encoding='UTF-8'?>

<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<SOAP-ENV:Header>

<wsD xmlns="?????/?????"><UUID>THE ID I NEED</UUID></wsID>

</SOAP-ENV:Header>

<SOAP-ENV:Body>

<Connect_ws????Response xmlns="?????/??????">

</Connect_ws?????Response>

</SOAP-ENV:Body>

</SOAP-ENV:Envelope>

the wsdl i downloaded from the webservice provider and importet it for mapping into the esr

many thanks

baskar_gopalakrishnan2
Active Contributor
0 Likes

The xml parser throws error that your request message has some invalid closing or opening tags. I think you are also doing some work in XSL mapping. Better capture the message payload in pipeline steps after mapping  and test it in XMLSPY and see what line in the message has invalid syntax. This way you can correct the problem either in xsl mapping that cause this or in your message target structure.