在服务器上发布了一个webservices,用soapUI调用可以成功,
但是远程调用老是出现No such operation 'subscriptionUpdateNotifyRequest'这个错误? 
webservice地址:http://220.194.138.217:8080/axis/services/IsmpSpService?wsdl
这是客户端发的包信息 
POST /axisrvices/IsmpSpService HTTP/1.0 Content-Type: text/xml; charset=utf-8 Accept: application/soap+xml, application/dime, multipart/related, text/* User-Agent: Axis/1.4 Host: 220.194.138.217:8080 Cache-Control: no-cache Pragma: no-cache SOAPAction: "urn:#subscriptionUpdateNotify" Content-Length: 702  
<?xml version="1.0" encoding="UTF-8"?> 
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"xmlns:xsd="http://www.w3.org/2001/XMLSchema"xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> 
<soapenv:Body> 
<subscriptionUpdateNotifyRequest xmlns="http://type.schema.ismp-sp.cnc.com"> 
<sequenceNo xmlns="">10 <quenceNo> 
<srcDeviceId xmlns="">149901020001 </srcDeviceId> 
<opFlag xmlns="">1 </opFlag> 
<userIdType xmlns="">1 </userIdType> 
<userId xmlns="">008618887498 </userId> 
<spId xmlns="">1040000044 </spId> 
<productId xmlns="">90120111141040000000022 </productId> 
<updateTime xmlns="">2008-12-15T08:25:31.310Z </updateTime> 
</subscriptionUpdateNotifyRequest> 
</soapenv:Body> 
</soapenv:Envelope> 
HTTP/1.1 500 Internal Server Error Server: Apache-Coyote/1.1 Content-Type: text/xml;charset=utf-8 Date: Mon, 15 Dec 2008 08:25:34 GMT Connection: close  
<?xml version="1.0" encoding="utf-8"?> 
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> 
<soapenv:Body> 
<soapenv:Fault> 
<faultcode xmlns:ns1="http://xml.apache.org/axis/">ns1:Client </faultcode> 
<faultstring>No such operation 'subscriptionUpdateNotifyRequest' </faultstring> 
<detail> <ns2:hostname xmlns:ns2="http://xml.apache.org/axis/">ibm </ns2:hostname> </detail> 
</soapenv:Fault> 
</soapenv:Body> 
</soapenv:Envelope> 
这应该就是错误信息,不知道什么原因,各位老大,帮帮忙呀

解决方案 »

  1.   

    你应该调用subscriptionUpdateNotify这个方法, 而不是subscriptionUpdateNotifyRequest.
      

  2.   

    你应该把你的请求到SOAPUI的请求对比,看有什么不同.
      

  3.   

    可是我不知道那边是怎么调用的,我这边只是按照别人的需求做这个接口,它所说的就是这2个方法,不是subscriptionUpdateNotifyRequest.
    是不是我发布的有什么问题?
      

  4.   

    方法名肯定是subscriptionUpdateNotify,你在调用程序中把方法名改成这个试了没?
      

  5.   

    你是用什么调用的?我现在也在做WEB服务调用的东西,能加QQ聊吗?我用WSDL4J做过.
      

  6.   

    这是他那边提供的wsdl文件内容
    <?xml version="1.0" encoding="UTF-8"?>
    <!-- edited with XMLSpy v2005 rel. 3 U (http://www.altova.com) by  () -->
    <wsdl:definitions xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:intf="http://schema.ismp-sp.cnc.com" 
    xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns="http://schema.ismp-sp.cnc.com" xmlns:tns3="http://type.schema.ismp-sp.cnc.com" 
    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
    targetNamespace="http://schema.ismp-sp.cnc.com" name="ismp-sp-WSDL-Interface">
    <wsdl:types>
    <schema targetNamespace="http://type.schema.ismp-sp.cnc.com" xmlns="http://www.w3.org/2001/XMLSchema" xmlns:enc2="http://type.schema.ismp-sp.cnc.com">
    <import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>
    <element name="subscriptionUpdateNotifyRequest">
    <complexType>
    <sequence>
    <element name="sequenceNo" type="xsd:string"/>
    <element name="srcDeviceId" type="xsd:string"/>
    <element name="opFlag" type="xsd:integer"/>
    <element name="userIdType" type="xsd:string"/>
    <element name="userId" type="xsd:string"/>
    <element name="spId" type="xsd:string"/>
    <element name="productId" type="xsd:string"/>
    <element name="packageId" type="xsd:string" minOccurs="0" maxOccurs="1"/>
    <element name="updateTime" type="xsd:dateTime"/>
    <element name="updateDesc" type="xsd:string" minOccurs="0" maxOccurs="1"/>
    <element name="subscriptionInfo" type="xsd:string" minOccurs="0" maxOccurs="1"/>
    </sequence>
    </complexType>
    </element>
    <element name="subscriptionUpdateNotifyResponse">
    <complexType>
    <sequence>
    <element name="sequenceNo" type="xsd:string"/>
    <element name="resultCode" type="xsd:integer"/>
    <element name="resultDescription" type="xsd:string" minOccurs="0"/>
    </sequence>
    </complexType>
    </element>
    <element name="modifyUserNumberRequest">
    <complexType>
    <sequence>
    <element name="sequenceNo" type="xsd:string"/>
    <element name="srcDeviceId" type="xsd:string"/>
    <element name="originalUserId" type="xsd:string"/>
    <element name="userIdType" type="xsd:string"/>
    <element name="newUserId" type="xsd:string"/>
    </sequence>
    </complexType>
    </element>
    <element name="modifyUserNumberResponse">
    <complexType>
    <sequence>
    <element name="sequenceNo" type="xsd:string"/>
    <element name="resultCode" type="xsd:integer"/>
    <element name="resultDescription" type="xsd:string" minOccurs="0"/>
    </sequence>
    </complexType>
    </element>
    </schema>
    </wsdl:types>
    <wsdl:message name="subscriptionUpdateNotifyRequest">
    <wsdl:part name="subscriptionUpdateNotifyRequestElement" element="tns3:subscriptionUpdateNotifyRequest"/>
    </wsdl:message>
    <wsdl:message name="subscriptionUpdateNotifyResponse">
    <wsdl:part name="subscriptionUpdateNotifyResponseElement" element="tns3:subscriptionUpdateNotifyResponse"/>
    </wsdl:message>
    <wsdl:message name="modifyUserNumberRequest">
    <wsdl:part name="modifyUserNumberRequestElement" element="tns3:modifyUserNumberRequest"/>
    </wsdl:message>
    <wsdl:message name="modifyUserNumberResponse">
    <wsdl:part name="modifyUserNumberResponseElement" element="tns3:modifyUserNumberResponse"/>
    </wsdl:message>
    <wsdl:portType name="IsmpSp">
    <wsdl:operation name="subscriptionUpdateNotify">
    <wsdl:input name="subscriptionUpdateNotifyRequest" message="tns:subscriptionUpdateNotifyRequest"/>
    <wsdl:output name="subscriptionUpdateNotifyResponse" message="tns:subscriptionUpdateNotifyResponse"/>
    </wsdl:operation>
    <wsdl:operation name="modifyUserNumber">
    <wsdl:input name="modifyUserNumberRequest" message="intf:modifyUserNumberRequest"/>
    <wsdl:output name="modifyUserNumberResponse" message="intf:modifyUserNumberResponse"/>
    </wsdl:operation>
    </wsdl:portType>
    <wsdl:binding name="IsmpSpSoapBinding" type="tns:IsmpSp">
    <wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
    <wsdl:operation name="subscriptionUpdateNotify">
    <wsdlsoap:operation soapAction="urn:#subscriptionUpdateNotify" style="document"/>
    <wsdl:input>
    <wsdlsoap:body use="literal"/>
    </wsdl:input>
    <wsdl:output>
    <wsdlsoap:body use="literal"/>
    </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name="modifyUserNumber">
    <wsdlsoap:operation soapAction="urn:#modifyUserNumber" style="document"/>
    <input>
    <wsdlsoap:body use="literal"/>
    </input>
    <output>
    <wsdlsoap:body use="literal"/>
    </output>
    </wsdl:operation>
    </wsdl:binding>
    <wsdl:service name="IsmpSpService">
    <wsdl:port name="IsmpSp" binding="intf:IsmpSpSoapBinding">
    <wsdlsoap:address location="http://localhost:7001/IsmpSp.jws"/>
    </wsdl:port>
    </wsdl:service>
    </wsdl:definitions>
      

  7.   

    他们的WSDL给出的操作名也是subscriptionUpdateNotify啊。
    <wsdl:portType name="IsmpSp"> 
    <wsdl:operation name="subscriptionUpdateNotify"> 
    <wsdl:input name="subscriptionUpdateNotifyRequest" message="tns:subscriptionUpdateNotifyRequest"/> 
    <wsdl:output name="subscriptionUpdateNotifyResponse" message="tns:subscriptionUpdateNotifyResponse"/> 
    </wsdl:operation> 
    <wsdl:operation name="modifyUserNumber"> 
    <wsdl:input name="modifyUserNumberRequest" message="intf:modifyUserNumberRequest"/> 
    <wsdl:output name="modifyUserNumberResponse" message="intf:modifyUserNumberResponse"/> 
    </wsdl:operation> 
    </wsdl:portType> 
    我不懂你说你不要调用是什么意思,你不是要写SOAP消息包的吗?你是说他们就给你subscriptionUpdateNotifyRequest方法,你直接调用?
      

  8.   

    <soapenv:Body> 
    <subscriptionUpdateNotifyRequest xmlns="http://type.schema.ismp-sp.cnc.com"> 
    <sequenceNo xmlns="">10 <quenceNo> 
    <srcDeviceId xmlns="">149901020001 </srcDeviceId> 
    <opFlag xmlns="">1 </opFlag> 
    <userIdType xmlns="">1 </userIdType> 
    <userId xmlns="">008618887498 </userId> 
    <spId xmlns="">1040000044 </spId> 
    <productId xmlns="">90120111141040000000022 </productId> 
    <updateTime xmlns="">2008-12-15T08:25:31.310Z </updateTime> 
    </subscriptionUpdateNotifyRequest> 
    </soapenv:Body> 
    </soapenv:Envelope> 
    这个消息包中的<subscriptionUpdateNotifyRequest xmlns="http://type.schema.ismp-sp.cnc.com"> 这里肯定是要是WSDL中的操作名,这个是不能错的。
      

  9.   

    soap消息里要注意命名空间的问题