I think the actual problem with this WSDL is that the name used on the
<wsdl:fault> element within the <wsdl:binding>/<wsdl:operation> doesn't
match that used on the corresponding
<wsdl:portType>/<wsdl:operation>/<wsdl:fault>. Here's the former
<wsdl:portType>/<wsdl:operation>:
<wsdl:operation name="SDD2TransportReplyOp">
<wsdl:input message="tns:SDD2TransportReplySoapIn" />
<wsdl:output message="tns:SDD2TransportReplySoapOut" />
<wsdl:fault name="SDD2ErrorFault" message="tns:SDD2Error" />
</wsdl:operation>
Here's the <wsdl:binding>/<wsdl:operation>/<wsdl:fault>:
<wsdl:fault name="SDD2Error">
<soap:fault use="literal" name="SDD2ErrorFault" namespace="" />
</wsdl:fault>
Note "SDD2ErrorFault" name on the first <wsdl:fault>, vs. "SDD2Error"
name on the second. The use of a name attribute on a <soap:fault> is
required by the BP (not by WSDL), but according to BP it must always
match that of the enclosing <wsdl:fault> element - so the WSDL is not
BP-compliant in any case.
- Dennis
Dennis M. Sosnoski
SOA and Web Services in Java
Training and Consulting
http://www.sosnoski.com - http://www.sosnoski.co.nz
Seattle, WA +1-425-939-0576 - Wellington, NZ +64-4-298-6117
Amila Suriarachchi wrote:
this is an axis2 problem. please feel free to log a jira.
Here is the problem.
In your wsdl contains a fault element and its soap binding as follows.
<wsdl:fault name="SDD2ErrorFault" message="tns:SDD2Error" />
in binding
<wsdl:fault name="SDD2Error">
<soap:fault use="literal" name="SDD2ErrorFault" namespace="" />
</wsdl:fault>
according to the wsdl 1.1 specification and the ws-basic profile your
wsdl is correct.
see
http://www.ws-i.org/Profiles/BasicProfile-1.1.html#name_Attribute_on_Faults
<http://www.ws-i.org/Profiles/BasicProfile-1.1.html#name_Attribute_on_Faults>
http://www.w3.org/TR/wsdl#_soap:fault
i.e. we have to pick the wsdl:fault, using the soap:fault element
(using the name attribute) in the soap binding. and this name is an
manadatory field.
but in axis2 it picks the wsdl:fault, using the wsdl:fault element
(using the name attribute).
therefore if you interchange the names as follows it will work.
<wsdl:fault name="SDD2ErrorFault">
<soap:fault use="literal" name="SDD2Error" namespace="" />
</wsdl:fault>
Amila.
--
Amila Suriarachchi,
Software Engineer,
WSO2 Inc.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]