wsdl fun (re: ACTION: LeeF to try SPARQL WSDL files with Woden validator, report results.)

Howdy,

Summary:

There are a few namespace errors in the querySoap binding that cause the 
WSDL to fail to validate. This diff fixes all the errors and the resulting 
WSDL validates successfully with woden.

88,89c88,89
<     <fault ref="MalformedQuery" wsoap:code="soap:Sender" />
<     <fault ref="QueryRequestRefused" wsoap:code="soap:Sender" />
---
>     <fault ref="tns:MalformedQuery" wsoap:code="wsoap:Sender" />
>     <fault ref="tns:QueryRequestRefused" wsoap:code="wsoap:Sender" />
91c91
<     <operation ref="query" 
wsoap:mep="http://www.w3.org/2003/05/soap/mep/request-response" />
---
>     <operation ref="tns:query" 
wsoap:mep="http://www.w3.org/2003/05/soap/mep/request-response" />


Details:

I downloaded the validation code from 
http://dev.w3.org/cvsweb/2006/wsdlConverter/ along with the woden jars 
that are archived there. My first attempt at running the validator against 
http://www.w3.org/2001/sw/DataAccess/proto-wd/sparql-protocol-query.wsdl 
gave this error:

"""
[Error] sparql-protocol-query.wsdl:12:71: cvc-elt.1: Cannot find the 
declaration of element 'description'.
Something went really wrong!
WSDLException: faultCode=OTHER_ERROR: WSDLException thrown because Woden 
does not yet resolve namespace-only schema imports. This is a 'NOT YET 
SUPPORTED' error which will be fixed for Milestone 4.: 
"""

So I dutifully went off to 
http://cvs.apache.org/dist/ws/woden/milestones/1.0.0M4-incubating/ and 
grabbed the M4 build of woden. Running against our WSDL now gives:

"""
panicale:~/My Documents/work/semantic-web/DAWG/wsdl-converter 
160>./validate 
http://www.w3.org/2001/sw/DataAccess/proto-wd/sparql-protocol-query.wsdl
[Error] 0:0,WSDL507,Could not create a QName from the string 
"soap:Sender".,org.apache.woden.WSDLException:WSDLException (at 
/description/binding[3]/fault[1]): faultCode=UNBOUND_PREFIX: Unable to 
determine namespace of 'soap:Sender'.
[Error] 0:0,WSDL507,Could not create a QName from the string 
"soap:Sender".,org.apache.woden.WSDLException:WSDLException (at 
/description/binding[3]/fault[2]): faultCode=UNBOUND_PREFIX: Unable to 
determine namespace of 'soap:Sender'.
[Error] 0:0,Binding-0055,The binding 'querySoap' does not define bindings 
for the interface operation 
'{http://www.w3.org/2005/08/sparql-protocol-query/#}query'. When a binding 
specifies an interface it must specify bindings for all of the interfaces 
operations.
[Error] 0:0,BindingFault-0058,The interface fault specified for this 
binding fault has already been specified on another binding fault. Each 
binding fault within a binding must specify a unique interface fault.

Sorry, this document is not valid.
"""

"Well," I thought, "at least it apologized."

The first comment is spot-on accurate. We don't define the NS prefix soap: 
anywhere; without fully understanding the semantics here, I assume that 
this should be the wsoap: namespace, so I changed that, which eliminated 
the first two errors.

The next error was resolved by changing the operation element inside the 
querySoap binding to be properly scoped inside the tns: namespace, leaving 
me with one remaining error. That last error is similarly resolved by 
properly placing the referenced faults in the querySoap binding in the 
tns: namespace, at which point I was greeted with:

"""
panicale:~/My Documents/work/semantic-web/DAWG/wsdl-converter 
165>./validate file:./tmp/sparql-protocol-query.wsdl

This document is valid. Congratulations.
"""

I will send information on the WSDL 1.1 to WSDL 2.0 XSLT later in the 
week.

Lee

Received on Tuesday, 21 March 2006 16:39:04 UTC