WSDL警告:有缺陷的soapbind:fault元素。那是什么意思?

时间:2011-06-19 20:19:11

标签: java xml web-services soap wsdl

以下是我的WSDL文件的片段;

<wsdl:portType name="MtchWS">                                                 
    <wsdl:operation name="inference">
        <wsdl:input message="tns:inferencerequest" name="inferencerequest"/>
        <wsdl:output message="tns:inferenceresponse" name="inferenceresponse"/>
        <wsdl:fault message="tns:errorresponse" name="errorresponse"/>             
    </wsdl:operation>
</wsdl:portType>

<wsdl:binding name="MtchWSBinding" type="tns:MtchWS">                  
    <soap:binding style="document"                                                   
        transport="http://schemas.xmlsoap.org/soap/http"/>                           
    <wsdl:operation name="inference">
        <soap:operation soapAction="http://www.mywebsite.com/webservice"/>           
        <wsdl:input name="inferencerequest">
            <soap:body use="literal"/>                                               
        </wsdl:input>
        <wsdl:output name="inferenceresponse">
            <soap:body use="literal"/>
        </wsdl:output>
        <wsdl:fault name="errorreponse">
            <!-- <soap:fault use="literal"/>-->
        </wsdl:fault>
    </wsdl:operation>
</wsdl:binding>

<wsdl:service name="MtchWSService">
    <wsdl:port binding="tns:MtchWSBinding" name="MtchWSPort">          
        <soap:address location="http://localhost:8080/mwp/mws"/>             
    </wsdl:port>
</wsdl:service>       

在上面的一行中(包括“wsdl:binding name =”MtchWSBinding“type =”tns:MtchWS“)我收到警告说;

WS-I:(BP2032)有缺陷的soapbind:fault元素:“name”属性值与父元素wsdl:fault上的“name”属性的值不匹配。

这意味着什么,我该如何解决这个问题?我的网络服务似乎工作正常,但我有一些其他问题(使用WSDL2ObjC),我认为这是与此警告有关。

TNX

1 个答案:

答案 0 :(得分:2)

好的我修好了;

刚刚添加了

<wsdl:fault name="errorresponse">
             <soap:fault name="errorresponse" use="literal"/>
        </wsdl:fault>
相关问题