Note that there are some explanatory texts on larger screens.

plurals
  1. POSpring-WS: Automatic wsdl fault generation/association
    primarykey
    data
    text
    <p>I am using DynamicWsdl11Definition in spring-ws to generate my wsdl spec. Eventually, I am getting a spec without wsdl faults attached to wsdl operations as I don't know how to associate particular wsdl/soap operations with particular wsdl faults automatically. How can I do that? Is there any way to associate wsdl faults with wsdl operations in the XSD schema?</p> <p>Here is a portion from my XSD:</p> <pre><code> &lt;xs:element name="setContextRequest"&gt; &lt;xs:complexType&gt; &lt;xs:sequence&gt; &lt;xs:element minOccurs="0" name="usageContext" nillable="true" type="xs:string"/&gt; &lt;/xs:sequence&gt; &lt;/xs:complexType&gt; &lt;/xs:element&gt; &lt;xs:element name="setContextResponse"&gt; &lt;xs:complexType&gt; &lt;xs:sequence&gt; &lt;xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/&gt; &lt;/xs:sequence&gt; &lt;/xs:complexType&gt; &lt;/xs:element&gt; </code></pre> <p>Here is my exception:</p> <pre><code> &lt;xs:element name="InvalidSessionException"&gt; &lt;xs:complexType&gt; &lt;xs:sequence&gt; &lt;xs:element minOccurs="0" name="InvalidSessionException" nillable="true" type="fault:InvalidSession"/&gt; &lt;/xs:sequence&gt; &lt;/xs:complexType&gt; &lt;/xs:element&gt; </code></pre> <p>Here is WSDL spec:</p> <pre><code> &lt;wsdl:operation name="setContext"&gt; &lt;soap:operation soapAction=""/&gt; &lt;wsdl:input name="setContextRequest"&gt; &lt;soap:body use="literal"/&gt; &lt;/wsdl:input&gt; &lt;wsdl:output name="setContextResponse"&gt; &lt;soap:body use="literal"/&gt; &lt;/wsdl:output&gt; &lt;/wsdl:operation&gt; </code></pre> <p>My question is on how to associate teh fault with that operation eventually to end up with:</p> <pre><code> &lt;wsdl:operation name="setContext"&gt; &lt;soap:operation soapAction=""/&gt; &lt;wsdl:input name="setContextRequest"&gt; &lt;soap:body use="literal"/&gt; &lt;/wsdl:input&gt; &lt;wsdl:output name="setContextResponse"&gt; &lt;soap:body use="literal"/&gt; &lt;/wsdl:output&gt; &lt;wsdl:fault name="invalidSession" type="InvalidSession"/&gt; &lt;/wsdl:operation&gt; </code></pre> <p>Thanks.</p> <p>ps: I'm setting requestSuffix, responseSuffix and faultSuffix, thus able to generate wsdl fault messages too.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload