cancel
Showing results for 
Search instead for 
Did you mean: 

RFC to Webservice - Web service has multiple messages

Former Member
0 Kudos

Hi,

I am working on RFC to web service scenario (Synchronous).

Imported webservice in external definition and the web service has 3 messages in it.

1. header

2. requestdoc

3. response.

while creating message interface, i can select only one input message (here i have to pass values for both Header & request doc). if i create 2 separate message interfaces one for header & one for requestdoc, how can i add both of them as target messages in meesage mapping? it gives me error if i add multiple target messages because the mode is synchronous.

How do we map when we have multiple messages in a web

appreciate your help.

Thanks,

Mahesh

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi Mark,

I did changes as you said. now i am receiving error *(com.sap.aii.af.ra.ms.api.DeliveryException: invalid content type for SOAP: TEXT/PLAIN; HTTP 200 OK)* see below.

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

- <!-- Inbound Message

-->

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

<SAP:Category>XIAdapterFramework</SAP:Category>

<SAP:Code area="MESSAGE">GENERAL</SAP:Code>

<SAP:P1 />

<SAP:P2 />

<SAP:P3 />

<SAP:P4 />

<SAP:AdditionalText>com.sap.aii.af.ra.ms.api.DeliveryException: invalid content type for SOAP: TEXT/PLAIN; HTTP 200 OK</SAP:AdditionalText>

<SAP:ApplicationFaultMessage namespace="" />

<SAP:Stack />

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

</SAP:Error>

markangelo_dihiansan
Active Contributor
0 Kudos

Hello,

What you can do is to use the MessageTransformBean module in the SOAP Receiver CC. Here is the link from SAP Help

http://help.sap.com/saphelp_nwpi711/helpdata/en/57/0b2c4142aef623e10000000a155106/frameset.htm

Now, to find the correct content type, execute your WS using SOAP UI. Then go to the request part and click on the Raw tab, Use the content type found there on your SOAP Receiver CC.

PS: Avoid double-posting.

Hope this helps,

Marl

Former Member
0 Kudos

Solved problem by using XSLT mapping.

markangelo_dihiansan
Active Contributor
0 Kudos

Hello,

I guess there is no other choice but to create a message type containing both the header and the request doc. The reason for this is that the values for the header and request doc are dynamic. Use this message type instead of the WSDL message in your inbound interface.

Hope this helps,

Mark

Edited by: Mark Dihiansan on Aug 9, 2011 7:01 AM

baskar_gopalakrishnan2
Active Contributor
0 Kudos

One ideal way is use request and response in the mapping structure. Use XSLT mapping to create header and check no soap envelope in the soap channel. This way you can handle one mapping structure at a time. if your header fields are pretty constants then use dynamic configuration or variable substitution to assign header fields. In the operation mapping specify XSLT mapping first followed by message mapping.