连接到 webservice 结果 com.sun.xml.internal.ws.client.ClientTransportException:服务器发送 HTTP 状态代码 200:OK
Connecting to webservice results in com.sun.xml.internal.ws.client.ClientTransportException: The server sent HTTP status code 200: OK
我使用 sun-jaxws 制作了 wsdl。我在 Netbeanse 中创建了 Web 服务客户端,并成功调用了 wsdl Web 服务。然后我将我的 nginx 服务器配置为通过 https 访问 Web 服务。当我通过 https 调用服务时,出现错误 com.sun.xml.internal.ws.client.ClientTransportException: The server sent HTTP status code 200: OK
我的 wsdl 可用地址 https://somesite.com/mywsdl/?wsdl
。在 wsdl 中我看到这样的服务位置:
<service name="GenericService">
<port name="GenericServicePort" binding="tns:GenericServicePortBinding">
<soap:address location="https://somesite.com:443/mywsdl"/>
</port>
</service>
不知道是我的nginx配置问题,还是我的jaxws问题。
问题出在我的 url 中的额外斜线中。我将 url 从 https://somesite.com/mywsdl/?wsdl
更改为 https://somesite.com/mywsdl?wsdl
,问题消失了。
我使用 sun-jaxws 制作了 wsdl。我在 Netbeanse 中创建了 Web 服务客户端,并成功调用了 wsdl Web 服务。然后我将我的 nginx 服务器配置为通过 https 访问 Web 服务。当我通过 https 调用服务时,出现错误 com.sun.xml.internal.ws.client.ClientTransportException: The server sent HTTP status code 200: OK
我的 wsdl 可用地址 https://somesite.com/mywsdl/?wsdl
。在 wsdl 中我看到这样的服务位置:
<service name="GenericService">
<port name="GenericServicePort" binding="tns:GenericServicePortBinding">
<soap:address location="https://somesite.com:443/mywsdl"/>
</port>
</service>
不知道是我的nginx配置问题,还是我的jaxws问题。
问题出在我的 url 中的额外斜线中。我将 url 从 https://somesite.com/mywsdl/?wsdl
更改为 https://somesite.com/mywsdl?wsdl
,问题消失了。