Hi Devs,

 

I am trying to use Axis2 1.3 to call a WS which is
document-literal-unwrapped, i.e. SOAP message BODY should contain
multiple children elements as shown below - 

 

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

   <soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/";>

      <soapenv:Body>

            <ns1:ERR_STATUS
xmlns:ns1="http://tempuri.org/wsATD/schemas";>

               <ns1:ERR_CDE>1</ns1:ERR_CDE>

               <ns1:ERR_SUB_CDE>2</ns1:ERR_SUB_CDE>

            </ns1:ERR_STATUS>

            <ns1:USER_DATA>

               <ns1:LN>ln</ns1:LN>

               <ns1:FIID>fiid</ns1:FIID>

               <ns1:REGN>regn</ns1:REGN>

               <ns1:BRCH>brch</ns1:BRCH>

               <ns1:USER_GRP>1</ns1:USER_GRP>

               <ns1:USER_NUM>3</ns1:USER_NUM>

            </ns1:USER_DATA>

      </soapenv:Body>

   </soapenv:Envelope>

 

I have scanned through the Axis2 source code and looked at various
receivers including
org.apache.axis2.receivers.RawXMLINOutMessageReceiver.java but all of
them seem to be dealing with first child element of the body element.
More org.apache.axis2.client.ServiceClient only seems to support
doc-literal wrapped style.

 

So my question is - 

1.       Does axis2 support this type of soap messaging (As shown in
example above)? I understand WS-I
1.1(http://www.ws-i.org/Profiles/BasicProfile-1.1-2004-08-24.html#WSDLMS
GS) seems to allow only one Message part but it doesn't clarify about
the format of the message on the wire. So it is nice to know what
support we have for that in Axis2.

2.       I tried using wsdl2java for ADB with -uw option, but that seems
to only change the stub interface, but actual message on wire still
looks wrapped. So is -uw option, just to alter stub interface & doesn't
have any impact on soap message generated.

 

 

Regards, Narayan

 

Inline Attachments:

1.      WSDL

<definitions name="wsATD"
targetNamespace="http://tempuri.org/wsATD/definitions";
xmlns="http://schemas.xmlsoap.org/wsdl/";

    xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/";
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";

    xmlns:typens="http://tempuri.org/wsATD/schemas";
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";
xmlns:wsdlns="http://tempuri.org/wsATD/definitions";

    xmlns:xsd="http://www.w3.org/2001/XMLSchema";> 

    <types>

        <xsd:schema elementFormDefault="qualified"
targetNamespace="http://tempuri.org/wsATD/schemas";>

 

            <xsd:complexType name="ERR_STATUSType">

                <xsd:sequence>

                    <xsd:element minOccurs="0" name="ERR_CDE"
type="xsd:short" />

                    <xsd:element minOccurs="0" name="ERR_SUB_CDE"
type="xsd:short" />

                </xsd:sequence>

            </xsd:complexType>

            <xsd:complexType name="USER_DATAType">

                <xsd:sequence>

                    <xsd:element minOccurs="0" name="LN"
type="xsd:string" />

                    <xsd:element minOccurs="0" name="FIID"
type="xsd:string" />

                    <xsd:element minOccurs="0" name="REGN"
type="xsd:string" />

                    <xsd:element minOccurs="0" name="BRCH"
type="xsd:string" />

                    <xsd:element minOccurs="0" name="USER_GRP"
type="xsd:short" />

                    <xsd:element minOccurs="0" name="USER_NUM"
type="xsd:long" />

                </xsd:sequence>

            </xsd:complexType>

            <xsd:element name="OPN50">

                <xsd:complexType>

                    <xsd:sequence>

                        <xsd:element name="ERR_STATUS"
type="typens:ERR_STATUSType" />

                        <xsd:element name="USER_DATA"
type="typens:USER_DATAType" />

                    </xsd:sequence>

                </xsd:complexType>

            </xsd:element>

        </xsd:schema>

    </types>

    <message name="opN50.ReplyMsg">

        <part element="typens:OPN50" name="parameters" />

    </message>

    <message name="opN50.RequestMsg">

        <part element="typens:OPN50" name="parameters" />

    </message>

    <portType name="wsATDPortType">

        <operation name="opN50">

            <input message="wsdlns:opN50.RequestMsg" />

            <output message="wsdlns:opN50.ReplyMsg" />

        </operation>

    </portType>

    <binding name="wsATDBinding" type="wsdlns:wsATDPortType">

        <soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http"; />

        <operation name="opN50">

            <documentation></documentation>

            <soap:operation soapAction="wsATD#opN50" />

            <input>

                <soap:body use="literal" />

            </input>

            <output>

                <soap:body use="literal" />

            </output>

        </operation>

    </binding>

    <service name="wsATD">

        <documentation></documentation>

        <port binding="wsdlns:wsATDBinding" name="wsATDPort">

            <soap:address location="http://localhost:8080/soap"; />

        </port>

    </service>

</definitions>

 

Actual message generated using ADB binding, generated using wsdl2java
with -uw option -

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

   <soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/";>

      <soapenv:Body>

         <ns1:OPN50 xmlns:ns1="http://tempuri.org/wsATD/schemas";>

            <ns1:ERR_STATUS>

               <ns1:ERR_CDE>1</ns1:ERR_CDE>

               <ns1:ERR_SUB_CDE>2</ns1:ERR_SUB_CDE>

            </ns1:ERR_STATUS>

            <ns1:USER_DATA>

               <ns1:LN>ln</ns1:LN>

               <ns1:FIID>fiid</ns1:FIID>

               <ns1:REGN>regn</ns1:REGN>

               <ns1:BRCH>brch</ns1:BRCH>

               <ns1:USER_GRP>1</ns1:USER_GRP>

               <ns1:USER_NUM>3</ns1:USER_NUM>

            </ns1:USER_DATA>

         </ns1:OPN50>

      </soapenv:Body>

   </soapenv:Envelope>0


*****************************************************
This email is issued by a VocaLink group company. It is confidential and 
intended for the exclusive use of the addressee only. You should not disclose 
its contents to any other person. If you are not the addressee (or responsible 
for delivery of the message to the addressee), please notify the originator 
immediately by return message and destroy the original message. The contents of 
this email will have no contractual effect unless it is otherwise agreed 
between a specific VocaLink group company and the recipient.
 
The VocaLink group companies include, among others: VocaLink Limited (Company 
No 06119048, VAT No. 907 9619 87) which is registered in England and Wales at 
registered office Drake House, Homestead Road, Rickmansworth, WD3 1FX. United 
Kingdom, Voca Limited (Company no 1023742, VAT No. 907 9619 87) which is 
registered in England and Wales at registered office Drake House, Three Rivers 
Court, Homestead Road, Rickmansworth, Hertfordshire. WD3 1FX. United Kingdom, 
LINK Interchange Network Limited (Company No 3565766, VAT No. 907 9619 87) 
which is registered in England and Wales at registered office Arundel House, 1 
Liverpool Gardens, Worthing, West Sussex, BN11 1SL and VocaLink Holdings 
Limited (Company No 06119036, VAT No. 907 9619 87) which is registered in 
England and Wales at registered office Drake House, Homestead Road, 
Rickmansworth, WD3 1FX. United Kingdom.
 
The views and opinions expressed in this email may not reflect those of any 
member of the VocaLink group. This message and any attachments have been 
scanned for viruses prior to leaving the VocaLink group network; however, 
VocaLink does not guarantee the security of this message and will not be 
responsible for any damages arising as a result of any virus being passed on or 
arising from any alteration of this message by a third party. The VocaLink 
group may monitor emails sent to and from the VocaLink group network.
 
This message has been checked for all email viruses by MessageLabs.
*************************************************************

Reply via email to