[R] Working cludge [Re: SSOAP fails with .types[[1]] : subscript out of bounds]

Steffen Neumann sneumann at ipb-halle.de
Tue Jun 22 14:06:12 CEST 2010


Hi,

so, last post from here unless I can provide any more input 
to fix the upstream package.

On Tue, 2010-06-22 at 10:02 +0200, Steffen Neumann wrote:
> So I got a bit further, the reason for the error is 
> that the WSDL *does not have* any <wsdl:types>...</wsdl:types>,

I created a local copy and inserted a dummy 
<wsdl:types>...</wsdl:types> element.

Then, my simple snippet works:

  library(SSOAP)

  # Hacked local copy
  w = processWSDL("./MassBank_Instruments")

  # this breaks genSOAPClientInterface()
  w = processWSDL("http://biomoby.org/services/wsdl/ipb-halle.de/MassBank_Instruments")
 
  mobyRequest <- "<moby:MOBY xmlns:moby=\"http://www.biomoby.org/moby\"/>"
  iface = genSOAPClientInterface(def = w, verbose=TRUE)
  cat(iface at functions$MassBank_Instruments(mobyRequest))

Hope that helped, 
Yours,
Steffen

"./MassBank_Instruments" that works:

<?xml version="1.0"?>
<wsdl:definitions name="MOBY_Central_Generated_WSDL"
                targetNamespace="http://biomoby.org/Central.wsdl"
                xmlns:tns="http://biomoby.org/Central.wsdl"
                xmlns:xsd1="http://biomoby.org/CentralXSDs.xsd"
                xmlns:xsd="http://www.w3.org/2001/XMLSchema"
                xmlns="http://schemas.xmlsoap.org/wsdl/"
                xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
                xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/">

    <wsdl:types>
        <xsd:schema attributeFormDefault="qualified" elementFormDefault="qualified" targetNamespace="http://biomoby.org/CentralXSDs.xsd">
          <xsd:element minOccurs="0" name="id" nillable="true" type="xsd:string"/>
        </xsd:schema>
  </wsdl:types>                
  <wsdl:message name="MassBank_InstrumentsInput">
          <wsdl:part name="data" type="xsd:string"/>
  </wsdl:message>

  <wsdl:message name="MassBank_InstrumentsOutput">
          <wsdl:part name="body" type="xsd:string"/>
  </wsdl:message>

  <wsdl:portType name="MassBank_InstrumentsPortType">
          <wsdl:operation name="MassBank_Instruments">
                 <wsdl:input message="tns:MassBank_InstrumentsInput"/>
                 <wsdl:output message="tns:MassBank_InstrumentsOutput"/>
          </wsdl:operation>
  </wsdl:portType>
                
  <wsdl:binding name="MassBank_InstrumentsBinding" type="tns:MassBank_InstrumentsPortType">
          <wsdlsoap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
          <wsdl:operation name="MassBank_Instruments"><!-- in essense, this is the name of the subroutine that is called -->
                 <wsdlsoap:operation soapAction='http://biomoby.org/#MassBank_Instruments' style='rpc'/>
                 <wsdl:input>
                         <wsdlsoap:body use="encoded" namespace="http://biomoby.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
                 </wsdl:input>
                 <wsdl:output>
                         <wsdlsoap:body use="encoded" namespace="http://biomoby.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
                 </wsdl:output>
          </wsdl:operation>
  </wsdl:binding>
                
  <wsdl:service name="MassBank_InstrumentsService">
          <wsdl:documentation>Authority: ipb-halle.de  -  retrieves available mass spectrometry instrument types used in MassBank
can be used to filter output when querying MassBank by peaklist and instrument types</wsdl:documentation>  <!-- service description goes here -->
          <wsdl:port name="MassBank_InstrumentsPort" binding="tns:MassBank_InstrumentsBinding">
                 <wsdlsoap:address location="http://msbi.ipb-halle.de/axis/services/MassBank_Instruments"/>    <!-- URL to service scriptname -->
          </wsdl:port>
  </wsdl:service>

</wsdl:definitions>





-- 
IPB Halle                    AG Massenspektrometrie & Bioinformatik
Dr. Steffen Neumann          http://www.IPB-Halle.DE
Weinberg 3                   http://msbi.bic-gh.de
06120 Halle                  Tel. +49 (0) 345 5582 - 1470
                                  +49 (0) 345 5582 - 0
sneumann(at)IPB-Halle.DE     Fax. +49 (0) 345 5582 - 1409



More information about the R-help mailing list