help with SSOAP (can't find working examples)

3 messages Options
Embed this post
Permalink
Hari Krishna Dara-2

help with SSOAP (can't find working examples)

Reply Threaded More More options
Print post
Permalink
First of all, let me confess that I am a newbie to R and don't know
much about the language or the environment. We have a need for
plugging in R in our production runtime and need the ability to pull
data out of our existing services. I am trying to see if I can take
advantage of SSOAP such that we can expose the data via webservices
and use SSOAP to call into them. Our runtime is mostly composed of
python, so the idea is to use rpy2 to interface from python to R, and
use SSOAP to call back into python modules where needed.

Now the problem is that I have hard time trying to find a single
example that works. I am using windows and here are the version
numbers:

R: 2.9.2
SSOAP: 0.5-3
XMLSchema: 0.1-1
XML: 2.6-0

The packages are up to date as per "Update packages". I tried all the
examples that came under library/SSOAP/examples directory and most
failed during genSOAPClientInterface(), while one failed right in
processWSDL(). This is the most common error during
genSOAPClientInterface():

Error in paste(" .elementFormQualified", .elementFormQualified, sep = " = ") :
  no slot of name "elementFormQualified" for this object of class "SchemaTypes"

There was only one reference to this error in the archives, and it
seems like the OP got the problem solved after updating XMLSchema
(which happened to be the same version as what I have). I tried a
couple of WSDL's that I have for creating python webservices, as well
as a "hello world" example, and they all have the same error as well.
While KEGG.wsdl, and others gave the above error, the eutils.wsdl gave
me the below error:

Error: Cannot resolve SOAP type in empty context

Interop.wsdl got me the below error:

Error: Cannot resolve string in SchemaCollection

nwis.wsdl failes in processWSDL() itself, with the below error:

Error in parse(text = paste(txt, collapse = "\n")) :
  unexpected input in "function(x, ..., obj = new( ‘"

I am most interested in solving the first error that I reported (as
the rest might be real issues with the wsdl syntax). Here is the full
output for KEGG.wsdl:

[1] "ArrayOfstring"
defining class ArrayOfstring
defining setAs() for ArrayOfstring
[1] "SSDBRelation"
defining class SSDBRelation
defining setAs() for SSDBRelation
[1] "ArrayOfSSDBRelation"
defining class ArrayOfSSDBRelation
defining setAs() for ArrayOfSSDBRelation
[1] "MotifResult"
defining class MotifResult
defining setAs() for MotifResult
[1] "ArrayOfMotifResult"
defining class ArrayOfMotifResult
defining setAs() for ArrayOfMotifResult
[1] "Definition"
defining class Definition
defining setAs() for Definition
[1] "ArrayOfDefinition"
defining class ArrayOfDefinition
defining setAs() for ArrayOfDefinition
[1] "LinkDBRelation"
defining class LinkDBRelation
defining setAs() for LinkDBRelation
[1] "ArrayOfLinkDBRelation"
defining class ArrayOfLinkDBRelation
defining setAs() for ArrayOfLinkDBRelation
Operation list_databases
resolve(, SchemaCollection) ArrayOfDefinition
resolve(, list) ArrayOfDefinition
Note: Method with signature "ArrayType#list" chosen for function "resolve",
 target signature "ArrayType#SchemaCollection".
 "SimpleSequenceType#SchemaCollection" would also be valid
Error in paste(" .elementFormQualified", .elementFormQualified, sep = " = ") :
  no slot of name "elementFormQualified" for this object of class "SchemaTypes"
In addition: Warning message:
In .findOrCopyClass(class2, classDef2, where, "subclass") :
  Class "VirtualXMLSchemaClass" is defined (with package slot
"XMLSchema") but no metadata object found to revise subclass
information---not exported?  Making a copy in package ".GlobalEnv"

I am not an expert in web services and WSDL, but I did compare them
with a few public WSDL samples and couldn't really make out an issue.
I would really appreciate any help or information in getting SSOAP to
work in my environment. Hopefully it is something trivial, like a
configuration issue.

And one more thing, I found version 0.5.4 of SSOAP at omegahat.org
website and tried that out as well, but it didn't make any difference.
I found a newer version of XMLSchema as well, but it didn't install
(with compilation errors). I have activeperl and mingw in the path.

Thank you,
Hari

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
sneumann-2

Re: help with SSOAP (can't find working examples)

Reply Threaded More More options
Print post
Permalink
Hi,

I can confirm this, just today
I tried to write a web service client.
Affected are both SSOAP-0.5-4 and SSOAP_0.4-6.

I can't access anonymous CVS atm. to check for recent fixes.
I am unable to map the error message to any of the items in
http://www.omegahat.org/SSOAP/Todo.html , is this already known ?

Yours,
Steffen

library(SSOAP)
Loading required package: XML
Loading required package: RCurl
Loading required package: bitops
> w = processWSDL("http://www.massbank.jp/api/services/MassBankAPI?wsdl")
Error: Cannot resolve ns:searchPeakDiff in SchemaCollection
In addition: Warning messages:
1: In function (node)  :
  skipping import node with no schemaLocation attribute
2: In processWSDL("http://www.massbank.jp/api/services/MassBankAPI?wsdl") :
  Ignoring additional <service><port> ... elements
> sessionInfo()
R version 2.8.1 (2008-12-22)
x86_64-pc-linux-gnu

locale:
LC_CTYPE=en_US.UTF-8;LC_NUMERIC=C;LC_TIME=en_US.UTF-8;LC_COLLATE=en_US.UTF-8;LC_MONETARY=C;LC_MESSAGES=en_US.UTF-8;LC_PAPER=en_US.UTF-8;LC_NAME=C;LC_ADDRESS=C;LC_TELEPHONE=C;LC_MEASUREMENT=en_US.UTF-8;LC_IDENTIFICATION=C

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base    

other attached packages:
[1] SSOAP_0.4-6    RCurl_1.3-0    bitops_1.0-4.1 XML_2.5-3  


w = processWSDL("http://www.massbank.jp/api/services/MassBankAPI?wsdl")
Error: Cannot resolve ns:searchPeakDiff in SchemaCollection
In addition: Warning messages:
1: In function (node)  :
  skipping import node with no schemaLocation attribute
2: In processWSDL("http://www.massbank.jp/api/services/MassBankAPI?wsdl") :
  Ignoring additional <service><port> ... elements

Enter a frame number, or 0 to exit  

 1: processWSDL("http://www.massbank.jp/api/services/MassBankAPI?wsdl")
 2: lapply(tmp, processWSDLBindings, doc, types)
 3: FUN(X[[1]], ...)
 4: lapply(els, processWSDLOperation, types, doc, namespaceDefinitions, typeDef
 5: FUN(X[[1]], ...)
 6: xmlSApply(msg, function(x) {
 7: xmlSApply.XMLNode(msg, function(x) {
 8: sapply(xmlChildren(X), FUN, ...)
 9: lapply(X, FUN, ...)
10: FUN(X[[1]], ...)
11: resolve(el, typeDefinitions)
12: resolve(el, typeDefinitions)
13: resolveError("Cannot resolve ", obj, " in ", class(context))




--
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

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Duncan Temple Lang

Re: help with SSOAP (can't find working examples)

Reply Threaded More More options
Print post
Permalink

Hi Steffen et al.

 The development version of SSOAP and XMLSchema I have on my machine
does complete the processWSDL() call without errors. I have to finish
off some tests before releasing these. It may take a few days before
I have time to work on this, but hopefully soon.

Thanks for the info.

 D.


Steffen Neumann wrote:

> Hi,
>
> I can confirm this, just today
> I tried to write a web service client.
> Affected are both SSOAP-0.5-4 and SSOAP_0.4-6.
>
> I can't access anonymous CVS atm. to check for recent fixes.
> I am unable to map the error message to any of the items in
> http://www.omegahat.org/SSOAP/Todo.html , is this already known ?
>
> Yours,
> Steffen
>
> library(SSOAP)
> Loading required package: XML
> Loading required package: RCurl
> Loading required package: bitops
>> w = processWSDL("http://www.massbank.jp/api/services/MassBankAPI?wsdl")
> Error: Cannot resolve ns:searchPeakDiff in SchemaCollection
> In addition: Warning messages:
> 1: In function (node)  :
>   skipping import node with no schemaLocation attribute
> 2: In processWSDL("http://www.massbank.jp/api/services/MassBankAPI?wsdl") :
>   Ignoring additional <service><port> ... elements
>> sessionInfo()
> R version 2.8.1 (2008-12-22)
> x86_64-pc-linux-gnu
>
> locale:
> LC_CTYPE=en_US.UTF-8;LC_NUMERIC=C;LC_TIME=en_US.UTF-8;LC_COLLATE=en_US.UTF-8;LC_MONETARY=C;LC_MESSAGES=en_US.UTF-8;LC_PAPER=en_US.UTF-8;LC_NAME=C;LC_ADDRESS=C;LC_TELEPHONE=C;LC_MEASUREMENT=en_US.UTF-8;LC_IDENTIFICATION=C
>
> attached base packages:
> [1] stats     graphics  grDevices utils     datasets  methods   base    
>
> other attached packages:
> [1] SSOAP_0.4-6    RCurl_1.3-0    bitops_1.0-4.1 XML_2.5-3  
>
>
> w = processWSDL("http://www.massbank.jp/api/services/MassBankAPI?wsdl")
> Error: Cannot resolve ns:searchPeakDiff in SchemaCollection
> In addition: Warning messages:
> 1: In function (node)  :
>   skipping import node with no schemaLocation attribute
> 2: In processWSDL("http://www.massbank.jp/api/services/MassBankAPI?wsdl") :
>   Ignoring additional <service><port> ... elements
>
> Enter a frame number, or 0 to exit  
>
>  1: processWSDL("http://www.massbank.jp/api/services/MassBankAPI?wsdl")
>  2: lapply(tmp, processWSDLBindings, doc, types)
>  3: FUN(X[[1]], ...)
>  4: lapply(els, processWSDLOperation, types, doc, namespaceDefinitions, typeDef
>  5: FUN(X[[1]], ...)
>  6: xmlSApply(msg, function(x) {
>  7: xmlSApply.XMLNode(msg, function(x) {
>  8: sapply(xmlChildren(X), FUN, ...)
>  9: lapply(X, FUN, ...)
> 10: FUN(X[[1]], ...)
> 11: resolve(el, typeDefinitions)
> 12: resolve(el, typeDefinitions)
> 13: resolveError("Cannot resolve ", obj, " in ", class(context))
>
>
>
>

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.