ZSI sample and issues with the WSDL

David Ross arragon at NOSPAMlineone.net
Wed Sep 5 11:18:11 EDT 2007


First two appologies, this is probably not a Python question, more
SOAP. And second, there is every possibilty I am terminally confused
having looked at this for two days now.

What I want is to create a Python SOAP server.  I am using the sample
which comes with ZSI, namely the Echo.wsdl and associated files.  I
then follow the instructions in the readme, and I CAN get a python
client and server to communicate.

But when I take the WSDL file and try to create a VB.NET program:

>wsdl.exe /language:VB /out:myProxyClass.vb Echo.wsdl 

I get:

Error: Unable to import binding 'EchoServer' from namespace
'urn:ZSI:examples'.
  - Unable to import operation 'Echo'.
  - Specified cast is not valid.

So I tried to set up the wsdl to point to my domain:


<?xml version="1.0" encoding="UTF-8"?>
<definitions 
  xmlns="http://schemas.xmlsoap.org/wsdl/"
  xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
  xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
  xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"
  xmlns:xsd="http://www.w3.org/2001/XMLSchema"
  xmlns:tns="http://www.me.org/Namespaces"
  targetNamespace="http://www.me.org/Namespaces" >

  <message name="EchoRequest">
    <part name="in_str" type="xsd:string"/>
  </message>
  <message name="EchoResponse">
    <part name="result" type="xsd:string"/>
  </message>

  <portType name="EchoServer">
    <operation name="Echo">
      <input message="tns:EchoRequest"/>
      <output message="tns:EchoResponse"/>
    </operation>
  </portType>

  <binding name="EchoServer" type="tns:EchoServer">
    <soap:binding style="document" 
                  transport="http://schemas.xmlsoap.org/soap/http"/>
    <operation name="Echo">
      <soap:operation soapAction="Echo"/>
        <input>
          <soap:body use="literal"/> 
        </input>
        <output>
          <soap:body use="literal"/> 
        </output>
    </operation>
  </binding>

  <service name="EchoServer">
    <port name="EchoServer" binding="tns:EchoServer">
      <soap:address location="http://localhost:7000"/>
    </port>
  </service>

</definitions>


I get a the same error:

Error: Unable to import binding 'EchoServer' from namespace
'http://www.me.org/Namespaces'.
  - Unable to import operation 'Echo'.
  - Specified cast is not valid.

My problem is that I'm not sure how to edit the ZSI example.  Worse,
this is pretty much as simple as it seems to get ;-(

Any pointers would be greatfully received.

I know I should ask in the MS forumns, but I was hoping someone would
understand the ZSI example better than I seem to.

Cheers

David

----
Note anti-spam in email address...



More information about the Python-list mailing list