[prev in list] [next in list] [prev in thread] [next in thread] 

List:       axis-user
Subject:    Re: Document/Literal Encoding and .NET interop
From:       Anne Thomas Manes <atmanes () gmail ! com>
Date:       2005-04-29 16:56:21
Message-ID: bf414ee605042909565e0c4c5a () mail ! gmail ! com
[Download RAW message or body]

If it is a .NET service, then it will have a WSDL file. If you know
the URL of the service endpoint, append it with "?wsdl", and you
should be able to retrieve the WSDL in a browser. (e.g.,
http://tempuri.org/VRSDataWS/ServerLink?wsdl). If you can't retrieve
it that way, ask the developer to send it to you. (I'm really
surprised that he didn't send it to you in the first place.)

Based on the example you provided, it does appear that the service
expects the following input message:

<xsd:element name="initTransfer">
   <xsd:complexType>
      <xsd:sequence>
         <xsd:element name="strData" type="xsd:string"/>
      </xsd:sequence>
   </xsd:complexType>
</xsd:element>

If you intend to send XML in the string, then it is appropriate for
Axis to escape the XML. .NET will automatically "unescape" it when it
receives it.

Anne

On 4/28/05, Elam Daly <elam@comcast.net> wrote:
> Anne Thomas Manes wrote:
> 
> >Your .NET web service provides a WSDL description of the service
> >interface. Run wsdl2java on this WSDL document, and Axis will generate
> >a Java client proxy for the service. Then you can just invoke
> >operations on this proxy. Axis will automatically generate
> >document/literal if that's what the WSDL says.
> >
> >And btw -- there's no way to send XML data such as
> >"<data1>data1</data1><data2>data2</data2>" as a string within another
> >element without escaping the XML.
> >
> >I expect that the actual input parameter is not in fact a string, it
> >is something like this:
> >
> ><element name="strData">
> >  <complexType>
> >    <sequence>
> >       <element name="data1" type="xsd:string"/>
> >       <element name="data2" type="xsd:string"/>
> >    </sequence>
> >  </complexType>
> ></element>
> >
> >Anne
> >
> >
> Hi Anne,
> 
> I'm pretty sure the web service is expecting one string.  This is the
> description of the .net web service:
> 
>       SOAP
> 
> The following is a sample SOAP request and response. The placeholders
> shown need to be replaced with actual values.
> 
> POST /ServerLink.asmx HTTP/1.1
> Host: [deleted]
> Content-Type: text/xml; charset=utf-8
> Content-Length: length
> SOAPAction: "http://tempuri.org/VRSDataWS/ServerLink/InitTransfer"
> 
> <?xml version="1.0" encoding="utf-8"?>
> <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xmlns:xsd="http://www.w3.org/2001/XMLSchema"
> xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
>   <soap:Body>
>     <InitTransfer xmlns="http://tempuri.org/VRSDataWS/ServerLink">
>       <strData>string</strData>
>     </InitTransfer>
>   </soap:Body>
> </soap:Envelope>
> 
> HTTP/1.1 200 OK
> Content-Type: text/xml; charset=utf-8
> Content-Length: length
> 
> <?xml version="1.0" encoding="utf-8"?>
> <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xmlns:xsd="http://www.w3.org/2001/XMLSchema"
> xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
>   <soap:Body>
>     <InitTransferResponse xmlns="http://tempuri.org/VRSDataWS/ServerLink">
>       <InitTransferResult>string</InitTransferResult>
>     </InitTransferResponse>
>   </soap:Body>
> </soap:Envelope>
> 
> Regardless, is the wsdl file something that is implicit in the service(
> can I extract it with Axis? ) or do I need to explicity ask the
> developer for the file?
> 
> Thanks for your help,
> Elam Daly
> 
>

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic