cancel
Showing results for 
Search instead for 
Did you mean: 

RPC- Style - Web Service

Former Member
0 Kudos

Hi. Dear Experts.

I have an scenario ECC-- Web Service. PI 7.1

The target webservice has RPC style , the issue is webservice call it doesn't work.

I imported the the wsdl as external defintion as "Using RPC style" but it doesn't work.

I searched on forum about that.. my question is PI 7.1 support RPC style or Do I need to convert the RPC to document style according the thread.?

http://scn.sap.com/thread/1625128

Regards.

Accepted Solutions (1)

Accepted Solutions (1)

iaki_vila
Active Contributor
0 Kudos

Hi Luis,

I had a similar problem with wsse security and i only received the SOAP envelope. You could try to put this in the Receiver SOAP adapter:

Regards

Former Member
0 Kudos

Hi. Thanks for your response.

Hi. Thanks for your answer.

I just checked the trace. I saw the WebServices it return the data in soap envelop response , but for PI only come as .

<ns1:getData soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns1="http://wwss.sunat.gob.pe/jboss-net/services/ConsultaRuc">

     <getDataReturn href="#id0"/>

</ns1:getData>

It seems the reference for ido is missing ,because on trace I see the reference for that with data. Like

<multiRef id="id0" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xsi:type="ns2:BeanDdp" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns2="urn:Data">

         <cod_1 xsi:type="xsd:string" xsi:nil="true"/>

         <cod_2 xsi:type="xsd:string" xsi:nil="true"/>

           ..............................................

Iñaki.

I tried to put the module but i have still the issue only PI received the Envelop.

Mark.

I tried your trick  the WS accept literal , but in case WS will response , PI will received only Envelop without multiref.

Regards

Former Member
0 Kudos

Finally I created a JavaMapping for Request , I create the payload as SOAP Request also

I activated the option on CC "Don't use SOAP envelop" and I got the data but as SOAP Envelop ,then I will created an XSLT/JavaMapping to get the final result.

It seeams a bug from SAP , I still waiting for the answer.

Regards

markangelo_dihiansan
Active Contributor
0 Kudos

Hello Luis,

RPC encoded is not WS-I (web services interoperability) compliant. Although the Receiver SOAP Adapter does not care if a WS is RPC or document-literal encoded, by default (without unchecking the Do Not Use SOAP Envelope) it expects a document-literal SOAP 1.1 webservice .

Hope this helps,

Mark

iaki_vila
Active Contributor
0 Kudos

Hi Luis,

I dont understand well your finally decission. Do you use the java mapping to do inside the call to the webservice or you use the java mapping to prepare the XML exactly how is needed for using later the SOAP Receiver?, I think is the second option .

Are you receiving the expected payload right now?

Let us to know if it's working and the SAP answer because this problem could be repeated to more people.

Good luck and regards.

Former Member
0 Kudos

Hi. to All.

Sap answer :  The response contains a multiRef .  The CC is a simple SOAP communication channel and I am afraid it cannot handle multiref response. As a workaround you need to use the SOAP Axis Adapter: SAP note 1039369 FAQ XI Axis Adapter.

Now based on my problem I tested with Axis Adapter. I checked this url http://host:port/XIAxisAdapter/MessageServlet  , the service is UP. However I got an issue.

com.sap.engine.interfaces.messaging.api.exception.MessagingException: javax.ejb.EJBException: Exception in getMethodReady() for stateless bean sap.com/com.sap.aii.axis.app*xml|com.sap.aii.adapter.axis.ejb.jar*xml|AFAdapterBean; nested exception is: com.sap.engine.services.ejb3.util.pool.PoolException: javax.ejb.EJBException: Exception raised from invocation of public void com.sap.aii.adapter.axis.modules.AFAdapterBean.ejbCreate() throws javax.ejb.CreateException method on bean instance com.sap.aii.adapter.axis.modules.AFAdapterBean@75115531 for bean sap.com/com.sap.aii.axis.app*xml|com.sap.aii.adapter.axis.ejb.jar*xml|AFAdapterBean; nested exception is: javax.ejb.CreateException: java.lang.NoClassDefFoundError: org/apache/axis/types/URI$MalformedURIException


At this point I'm stuck... according forums and  documentation the problem is  [ This error indicates the value of some addressing property is not correctly set and cannot be inserted in the addressing header. Most addressing properties (e.g., Action, ReplyTo, ) must be in the URI syntax ]

However the target URL is correct.

URL              : http://xxxx/jboss-net/services/QueryData

soapAction  : QueryData

This my WSDL

<wsdl:definitions targetNamespace="http://xxxx/jboss-net/services/QueryData"   --------- "

........................................

<wsdl:operation name="getPrincipalData">

      <wsdlsoap:operation soapAction="QueryData"/>                      


Do I miss something.?


Former Member
0 Kudos

Hi to All.

After many days "fighting" with SAP People .. finally I get the information of Web Service RPC Style.

According  his SAP Note recomendation 1039369 ( Check Update Note 1028961) . We need to unzip the  SDA File - AxisAdapter , add the libraries , the problem was with the path of new libraries  ... Finally we re-deployed the SDA now is working.

Only to say:  If you use this Axis Adapter . you will received one extra payload  on Integration Server by one multiref segment.


Regards

Former Member
0 Kudos

Hi Luis,

may I ask what do you mean when you say "you will receive one extra payload on IS by one multiref seg"??

I'm working with a 3rd Party WS, and cannot handle the response. Once I try to map it and send it to R/3 I've got problems with the multiref response. We've installed the Axis Adapter, and also I've added some swap payload bean just to try to map the actual payload I need with no success.

Moreover, I cannot see the 'Do not use SOAP envelope' option under the conversion parameters at the comm. channel as SAP suggests.

Any hint?

Cheers,

Edu

Answers (3)

Answers (3)

markangelo_dihiansan
Active Contributor
0 Kudos

Hello Luis,

When dealing with RPC-Style WSDLs, there is a trick to see if it will be accepting a document-literal type input (test in SOAP UI), for example:

I have this RPC-Style WS

I will try to pass a document-literal input by deleting some details in the SOAP Envelope e.g

soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"

and all xsi:types and then execute the request

If you are still able to get the same response, then all you need to do is to match the document-literal request to get the correct response. Otherwise, you need to build the RPC-Style request using Java/XSLT mapping.

Hope this helps,

Mark

baskar_gopalakrishnan2
Active Contributor
0 Kudos

As per note, I would not recommend you to convert RPC to Document style.

Reason: You are consuming webservice as client. The wSDL instance should bind to the rpc style coding implemented over target system. Use as RPC style and see how that works. If the problem is not resolved raise this query to SAP.

Former Member
0 Kudos

Hi Baskar.

Thanks for your response , I agree with you the wsdl in RPC sytle should bind to WS.

I just changed the external definition with Style RPC , now I got a response but no complete only i got the header response - soap envelop - without data.

I tried with External Tool SOAP UI , is ok but not for PI.

I will raise to SAP.

Regards

iaki_vila
Active Contributor
0 Kudos

Hi Luis,

As far as i know the version 7.0 and 7.1 has the same problem.

Check the note 856597:

  • Q: Does the RPC or Document style in WSDL play a role in the SOAP adapter?

            A: No.  These styles are used in WSDL to describe how the message is represented as a SOAP message. And this corresponds to how the XI payload is represented. You must make sure that your XI proxy is generating the valid payload according to the given WSDL in whatever the style. If this is not the case (e.g., your proxy is generated by another  WSDL and there is a mismatch in how the payload must look), you need to configure some mapping to match the payload.

           Related Questions "Can I convert an RPC styled WSDL to a document styled WSDL?"

  • Q: Can I convert an RPC styled WSDL to a document styled WSDL?

           A: It is difficult to answer yes or no because the answer depends on the WSDL instance and the implementation of the code that binds the XML instance to some native object. The problem comes from the fact that these two styles describe web services in different layers. The document style WSDL describes how one can bind an XML document to the SOAP message format. In contrast, the RPC style WSDL describes how one can bind an object to the SOAP message format. One can imagine that this works in two steps: first representing the object as an XML document and then binding this XML document to the SOAP message format. How this first step works is controlled by the SOAP encoding name. For the standard encoding specified in the SOAP specification, most objects can be easily described in an equivalent XML schema. Some special objects such as references and arrays must be represented by some special rules and some additional meta information in XML. This implies that these additional attributes and elements must also be described in the XML schema and the document style based proxy must set these values in the instance appropriately.

           One must however note that even if one has an equivalent document style  WSDL, this does not automatically guarantees the interoperability. Some  RPC styled service implementations have significant interoperability  problems such as requiring the xsi:type attribute for every element or  the SOAP encoding attribute at some particular element. If one has to  call such non conformant SOAP service, one must adjust the message accordingly.

           Attachment wsdl_style_samples. zip contains some examples of WSDL  documents and sample SOAP messages that illustrate how one can write an equivalent WSDL in another style.

           Related Questions "Does the RPC or Document style in WSDL play a role in the SOAP adapter?"

Regards