cancel
Showing results for 
Search instead for 
Did you mean: 

Error when transform WSDL message Response Source to message Response Target - Using WS with RPC Style and Tag Response <Multiref ...>

Former Member
0 Kudos

Hello Friends,

I have an Scenario ECC-->Web Service.

The target web service has RPC Style, only work the message request using "RPC Style" but message response to need transformation.

the problem is tag Multiref  <multiRef id="id0" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xsi:type="ns2:Parametro" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">

I need to idea for continue and resolve this problem.

thank you everybody.

kind regards

Luis M.

Accepted Solutions (0)

Answers (4)

Answers (4)

iaki_vila
Active Contributor
0 Kudos

Hi Luis.

To follow Mark suggestion, check this blog

Regards.

markangelo_dihiansan
Active Contributor
0 Kudos

Hi Luis,

Try using the multiRef message in the xsd. In the screenshot, you are using a MessageType.

Regards,

Mark

Former Member
0 Kudos

Hello Mark;

How to you apply Mulitiref Message in the XSD ?  You have a link of reference like support?

thanks

Regards

Luis

markangelo_dihiansan
Active Contributor
0 Kudos

Hi Luis,

"By applying multiref", what I meant was that load the xsd as the target message and then look for the multiref message in it (an xsd can contain many messages) as opposed to using the message type that you have created.

Regards,

Mark

former_member190293
Active Contributor
0 Kudos

Hi Mark!

I'm afraid that the problem is not in WSDL. The problem is that web service returns data in RPC Encoded format, which has to be converted to Document Literal format.

"When the Document Literal style is used, the XML document that is created is in a tree structure that resembles a common XML document. The RPC Encoded style creates a flat XML document with cross-references from an element to its children."

Regards, Evgeniy.

markangelo_dihiansan
Active Contributor
0 Kudos

Hi Evgeniy,

I'm not really sure, RPC format can be imported via WSDL using RPC style option.

Regards,

Mark

former_member190293
Active Contributor
0 Kudos

Hi Mark!

I doubt standard SOAP adapter ability to process SOAP RPC-encoded message with multiple root tags inside <SOAP:Body> tag.

May be I'm wrong.

Regards, Evgeniy.

markangelo_dihiansan
Active Contributor
0 Kudos

Hi Evgeniy,

I see what you mean , he has to use "Do Not Use SOAP Envelope" to retrieve the whole message and then filter the multiref.

Regards,

Mark

former_member190293
Active Contributor
0 Kudos

Hi Mark!

Exactly .

With something like this:

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

<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"

   xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">

    <xsl:key name="multiref-by-id" match="multiRef" use="@id"/>

    <xsl:template match="/">

        <xsl:copy>

            <xsl:apply-templates select="@*|*"/>

        </xsl:copy>

    </xsl:template>

    <xsl:template match="*[starts-with(@href, '#')]">

        <xsl:copy>

            <xsl:apply-templates select="@* |

             key('multiref-by-id', substring-after(@href, '#'))/@* |

            key('multiref-by-id', substring-after(@href, '#'))/node()"/>

        </xsl:copy>

    </xsl:template>

    <xsl:template match="@href[starts-with(., '#')] | multiRef[@id] | @soapenc:root"/>

    <xsl:template match="@*|node()">

        <xsl:copy>

            <xsl:apply-templates select="@*|node()"/>

        </xsl:copy>

    </xsl:template>

</xsl:stylesheet>

Thus, we'll get response structure described in WSDL.

Regards, Evgeniy.

former_member190293
Active Contributor
0 Kudos

Hi Luis!

Other way might be to use SOAP Axis receiver adapter with payload extraction = SOAP Body Child.

Regards, Evgeniy.

former_member190293
Active Contributor
0 Kudos

Hi Luis!

I would recommend to use XSLT mapping before your graphical mapping to move contents of <MultiRef> tag to Return tag contents.

By the way: do you get any error with this while performing end-to-end testing?

Wouldn't you please provide an example of response message in text format, not picture?

Regards, Evgeniy.