【发布时间】:2010-12-04 06:17:48
【问题描述】:
我正在尝试共同连接到第 3 方 SOAP Web 服务。当 HTTP SOAPAction 标头为空字符串 ("") 时,服务似乎可以工作。这是wsdl的sn-p:
<wsdl:binding name="detailsRequestMessage" type="tns:UssdPortType">
<soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
<wsdl:operation name="details">
<soap:operation soapAction=""/>
<wsdl:input>
<soap:body use="literal"/>
</wsdl:input>
<wsdl:output>
<soap:body use="literal"/>
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
您在哪里看到 soapAction=""
我使用 Axis2 (1.5) wsdl2java 生成了一个存根。
我希望得到以下结果(使用 SoapUI 运行时的成功输出):
POST /details HTTP/1.1
Accept-Encoding: gzip,deflate
Content-Type: text/xml;charset=UTF-8
SOAPAction: ""
User-Agent: Jakarta Commons-HttpClient/3.1
Host: some.host
Content-Length: 323
但是相反我得到了:
POST /details HTTP/1.1
Content-Type: text/xml; charset=UTF-8
SOAPAction: "http://some.url/wsussd/ussdtypes/UssdPortType/detailsRequest"
User-Agent: Axis2
Host: some.host
Content-Length: 300
有谁知道问题出在哪里或者我如何在程序中设置soapAction。
谢谢, 罗南
【问题讨论】:
标签: web-services axis2