Loading ...
Sorry, an error occurred while loading the content.

specifying xmlns of method with WSDL call?

Expand Messages
  • aviannachao
    Say I have the following WSDL sniplet:
    Message 1 of 3 , Sep 15, 2004
    • 0 Attachment
      Say I have the following WSDL sniplet:

      <wsdl:binding name="HelloWorldBinding" type="tns:HelloWorldPortType">
      <soap:binding style="document"
      transport="http://schemas.xmlsoap.org/soap/http"/>
      <wsdl:operation name="sayHello">
      <soap:operation soapAction=""/>
      <wsdl:input>
      <soap:body namespace="HelloWorld" use="literal"/>
      </wsdl:input>
      <wsdl:output>
      <soap:body namespace="HelloWorld" use="literal"/>
      </wsdl:output>
      </wsdl:operation>
      </wsdl:binding>

      With the namespace"HelloWorld" attribute in place in the <soap:body>
      element inside <wsdl:input>, when soaplite serializes the call, the
      XML it generates is:

      <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://
      schemas.xmlsoap.org/soap/envelope/"
      xmlns:namesp2="http://namespaces.soaplite.co
      m/perl" xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
      xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
      xmlns:xsd="http://www.w3.org/1999/XMLSchema"
      SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
      <SOAP-ENV:Body>
      <namesp1:sayHello xmlns:namesp1="HelloWorld">
      <sayHelloRequest xsi:type="namesp2:sayHelloRequest">
      [snip]
      </sayHelloRequest>
      </namesp1:sayHello>
      </SOAP-ENV:Body>
      </SOAP-ENV:Envelope>

      If the server that implemented this web service is Perl, it works
      fine. However, I am talking to a Biztalk server, and it must be
      having a hard time understainding <namesp1:sayHello xmlns:namesp1>,
      because it does receive the request, but it thinks the message is blank.

      I did a test by telnetting directly to the Biztalk server, and posting
      a SOAP request with <sayHello xmlns="HelloWorld"> and it worked fine.

      So my question is, how can I make soaplite serialize the call in that
      fashion?

      A follow up question would be, see the "namesp2" definition in the
      envelope and <sayHelloRequest> tag? well, where the hell did soaplite
      get that from? sayHelloRequest is a message in the HelloWorld
      namespace. The XML should look like:

      <SOAP-ENV:Envelope xmlns="HelloWorld" xmlns:SOAP-ENV="http://
      schemas.xmlsoap.org/soap/envelope/"
      xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
      xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
      xmlns:xsd="http://www.w3.org/1999/XMLSchema"
      SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
      <SOAP-ENV:Body>
      <sayHello>
      <sayHelloRequest>
      [snip]
      </sayHelloRequest>
      </sayHello>
      </SOAP-ENV:Body>
      </SOAP-ENV:Envelope>

      Help please!

      Thanks in advance!
    • Mark Fuller
      ... Look at: http://groups.yahoo.com/group/soaplite/message/3770 and http://groups.yahoo.com/group/soaplite/message/3843 Issac has done a lot with .Net and
      Message 2 of 3 , Sep 15, 2004
      • 0 Attachment
        --- aviannachao <aviannachao@...> wrote:
        > If the server that implemented this web service is
        > Perl, it works
        > fine. However, I am talking to a Biztalk server,
        > and it must be
        > having a hard time understainding <namesp1:sayHello
        > xmlns:namesp1>,
        > because it does receive the request, but it thinks
        > the message is blank.


        Look at:

        http://groups.yahoo.com/group/soaplite/message/3770

        and

        http://groups.yahoo.com/group/soaplite/message/3843

        Issac has done a lot with .Net and appears to be
        trying Biztalk.

        Mark



        __________________________________
        Do you Yahoo!?
        Yahoo! Mail - 50x more storage than other providers!
        http://promotions.yahoo.com/new_mail
      • Issac Goldstand
        ... From: aviannachao To: Sent: Wednesday, September 15, 2004 7:42 PM Subject: [soaplite] specifying xmlns
        Message 3 of 3 , Sep 19, 2004
        • 0 Attachment
          ----- Original Message -----
          From: "aviannachao" <aviannachao@...>
          To: <soaplite@yahoogroups.com>
          Sent: Wednesday, September 15, 2004 7:42 PM
          Subject: [soaplite] specifying xmlns of method with WSDL call?
          [snip]


          >
          > A follow up question would be, see the "namesp2" definition in the
          > envelope and <sayHelloRequest> tag? well, where the hell did soaplite
          > get that from? sayHelloRequest is a message in the HelloWorld
          > namespace. The XML should look like:
          >
          > <SOAP-ENV:Envelope xmlns="HelloWorld" xmlns:SOAP-ENV="http://
          > schemas.xmlsoap.org/soap/envelope/"
          > xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
          > xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
          > xmlns:xsd="http://www.w3.org/1999/XMLSchema"
          > SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
          > <SOAP-ENV:Body>
          > <sayHello>
          > <sayHelloRequest>
          > [snip]
          > </sayHelloRequest>
          > </sayHello>
          > </SOAP-ENV:Body>
          > </SOAP-ENV:Envelope>
          >

          Actually, from what I remember, .Net is very anal about explicit namespaces
          for everything, so just don't complain.

          Issac
        Your message has been successfully submitted and would be delivered to recipients shortly.