Edit:
Conclusion: It does not work and is unlikely to work without changing the service.
In the meantime, I would like to ask everyone who has similar experiences with non-functional SOAP/REST web-services, non-parsable WSDLS, non-validating XML-messages or other problems with service interoperability not to give up, but to report to the providers, to challenge them to improve the interoperability!
Those experiencing similar problems with BioMart can for example report to: mart-dev@ebi.ac.uk
Testing bioinformatics web-services can sometimes be a frustrating experience. It looks as if all the specs of interoperability are not worth the (white-) papers they are printed on.
I actually have had very little success in connecting to perl, SOAP-lite based web-services like BioMart, Kegg, etc.
Actually, I tried to use a generated Axis2 client and got an exception.
Then, I tried to validate the response message in SoapUI from BioMart, and it does not validate!
line 4: Expected element 'mart' instead of 'mart@http://www.biomart.org:80/MartServiceSoap' here in element getRegistryResponse@http://www.biomart.org:80/MartServiceSoap
So it's very unlikely that this is going to work at all, except with perl and SOAP::Lite. There are too many tiny glitches involved. To clean up this mess I intend to contact the Bimart developers and ask them to change their interface. In fact, it seems that nobody has tested that yet with Java, otherwise somebody would have noticed that it does not work.
Maybe, you wish to join me in this effort?
Hi Pierre,
actually it would surprise me if there were no problems. This reminds me of some experiences I encountered when I tried to use the highly appraised standardized SOAP web-services world (actually I wanted to ask a question about user's experiences with bioinfo services but didn't get that far). So, it is a bit like the famous radio yerevan, "In principle it's standardized, but everyone has different standards."
However, and not to just bash the providers, I can remember that we had successfully accessed biomart SOAP web-services with SoapUI. That tool is great for testing and building messages. Alternatively try a different SOAP stack like Axis2 to generate the binding.
I might give it a try and generate a simple Axis2 client, then I will edit and provide the
java code. So long there could be something wrong with the way you are trying to use the library. Also, Biomart is sensitive to the exact workflow of service calls.
This is what I just tried in soapui:
with SoapUI load the wsdl at: http://www.biomart.org/biomart/martwsdl
With other tools (eg curl, see comments), send the xml-message below to the
service endpoint address: http://www.biomart.org/biomart/martsoap
then call "getRegistry" as you did with the following message:
<soapenv:Envelope xmlns:soapenv="<a href=" http:="" schemas.xmlsoap.org="" soap="" envelope="" "="" rel="nofollow">http://schemas.xmlsoap.org/soap/envelope/" xmlns:mar="http://www.biomart.org:80/MartServiceSoap">
<soapenv:Header/>
<soapenv:Body>
<mar:getRegistry/>
</soapenv:Body>
</soapenv:Envelope>
Then you will get this response, which looks very much ok.
<soap:Envelope soap:encodingStyle="<a href=" http:="" schemas.xmlsoap.org="" soap="" encoding="" "="" rel="nofollow">http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<getRegistryResponse xmlns="<a href=" http:="" www.biomart.org:80="" MartServiceSoap"="" rel="nofollow">http://www.biomart.org:80/MartServiceSoap">
<mart>
<name xsi:type="xsd:string">ensembl</name>
<displayName xsi:type="xsd:string">ENSEMBL GENES 57 (SANGER UK)</displayName>
<database xsi:type="xsd:string">ensembl_mart_57</database>
<host xsi:type="xsd:string">www.biomart.org</host>
/biomart/martservice
<port xsi:type="xsd:string">80</port>
<visible xsi:type="xsd:int">1</visible>
<default xsi:type="xsd:int">1</default>
<serverVirtualSchema xsi:type="xsd:string">default</serverVirtualSchema>
<includeDatasets xsi:type="xsd:string"/>
<martUser xsi:type="xsd:string"/>
<redirect xsi:nil="true" xsi:type="xsd:int"/>
</mart>
Actually, I see we are using different marts, could you try the 'real' mart at http://www.biomart.org/biomart/martwsdl ?
Just sent my message to mart-dev, let's see what comes out of it.
I wanted to use a telephone, but was told to use a walkie-talkie instead... For now, no chance for the SOAP service, have to try the REST service instead. The developers say, they are working on porting BioMart to Java, which I appreciate.
I saw your messages on the mart-dev mailing Michael. Thanks for that. Yes, some answers were weird "your java thing cannot understand our service ? solution is: use REST..." :-/