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

809SOAP::Lite & WSDL - some questions (long)

Expand Messages
  • Jean-Jack M. Riethoven
    Sep 10, 2001
    • 0 Attachment

      I am trying to set up a SOAP service using the Perl SOAP::Lite modules, and
      I was up and running in less than 10 minutes (Kudos to the developer of

      Everything works fine from my little SOAP client, accessing the server
      directly. I am now trying to set up access via WSDL, and I am hopelessly
      lost :)

      I even slimmed down the server so that basically I give it a string and it
      should return the same string back. I hope you don't mind dumping you with
      source code and WSDL, but maybe a thousand people can see what I cannot.

      When I execute the client with the ->service() call I can see the .wsdl
      file being downloaded, the SOAP-server.pl being run (with a 500 error)...
      and an undefined result (obviously) returned. Running the client via ->uri
      and ->proxy works like a charm.

      My thought is the problem must be in WSDL, or in SOAP::Lite's WSDL
      handling, since a normal SOAP call directly to the server works.. So I'll
      list the WSDL first:

      <?xml version = "1.0"?>
      <definitions name="XEMBL"
      <message name="FullSequenceRequest">
      <part name="id" type="xsd:string" />
      <message name="FullSequenceResponse">
      <part name="result" type="xsd:string" />
      <portType name="XEMBLPortType">
      <operation name="FullSequence">
      <input message="tns:FullSequenceRequest" name="FullSequence"/>
      <output message="tns:FullSequenceResponse"
      name="FullSequenceResponse" />
      <binding name="XEMBLServiceBinding" type="tns:XEMBLPortType">
      <soap:binding style="rpc"
      transport="http://schemas.xmlsoap.org/soap/http" />
      <operation name="FullSequence">
      <soap:operation soapAction="" />
      <soap:body use="encoded"
      encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
      <soap:body use="encoded"
      encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" />
      <service name="XEMBLService">
      <documentation>Returns full information on EMBL Nucleotide Sequences
      formatted as Bsml XML or Agave XML</documentation>
      <port name="XEMBLPort" binding="tns:XEMBLServiceBinding">
      location="http://www.ebi.ac.uk:80/cgi-bin/xembl/SOAP-server.pl" />

      Basically, the server SOAP-server.pl is this:

      #!/sw/arch/bin/perl -w

      use SOAP::Transport::HTTP;

      -> dispatch_to('XEMBL')
      -> handle;

      package XEMBL;

      sub FullSequence

      my ($class, $acc_nr) = @_;
      my ($result);

      use LWP::Simple; # Use the LWP::Simple package.

      $result = $acc_nr;

      return $result;


      The client is as follows:


      # Simple program that connects to the SOAP server to retrieve
      # sequence information in either Bsml or AGAVE XML format.

      use SOAP::Lite; # SOAP API

      # THIS WORKS!
      # my $soap = SOAP::Lite
      # -> uri('http://www.ebi.ac.uk/XEMBL')
      # -> proxy('http://www.ebi.ac.uk/cgi-bin/xembl/SOAP-server.pl');

      my $soap = SOAP::Lite
      -> service('http://www.ebi.ac.uk/xembl/XEMBL.wsdl');

      $result = $soap->FullSequence('HSERPG');

      # with the use of ->service the result is always empty :(
      if ($result) {
      print $result->result();
      } else

      print "EMPTY!!!!\n\n";

      Thank you very much for your time!

      With kind regards,

      drs. Jean-Jack M. Riethoven

      EMBL Outstation - Hinxton pow@... ICQ#: 3433929
      European Bioinformatics Institute Phone: (+44) 1223 494635
      Wellcome Trust Genome Campus Fax : (+44) 1223 494468
      Hinxton, Cambridge CB10 1SD URL : http://industry.ebi.ac.uk/

      Need to find bioinformatics or molecular biology web sites or resources?
      Use BioWurld at http://www.ebi.ac.uk/biowurld
    • Show all 8 messages in this topic