间歇性javax.xml.ws.soap.SOAPFaultException:不合格{http://schemas.xmlsoap.org/soap/envelope/}Client fault

时间:2011-11-17 03:58:15

标签: java jboss jbossws solaris-10

我们正在使用JBossWS - Native (version 3.1.2)(标准JBoss EAP 5.1安装),我们间接得到以下异常......,有人知道吗?

如果我通过几次调用webservice进行测试它运行正常,但一旦部署到生产中我们就开始看到这个错误..大多数时候它工作正常..但有时我们看到这个错误..

我估计大约有10%的网络服务电话会收到此错误。

使用wsconsume

生成Web服务客户端
2011-11-17 09:35:05,652 ERROR [org.jboss.ws.core.CommonClient] (ajp-10.1.75.243-8209-5) Exception caught while (preparing for) performing the invocation:
javax.xml.ws.soap.SOAPFaultException: Unqualified {http://schemas.xmlsoap.org/soap/envelope/}Client fault
    at org.jboss.ws.core.jaxws.SOAPFaultHelperJAXWS.getSOAPFaultException(SOAPFaultHelperJAXWS.java:85)
    at org.jboss.ws.core.jaxws.binding.SOAP11BindingJAXWS.throwFaultException(SOAP11BindingJAXWS.java:107)
    at org.jboss.ws.core.CommonSOAPBinding.unbindResponseMessage(CommonSOAPBinding.java:558)
    at org.jboss.ws.core.CommonClient.invoke(CommonClient.java:396)
    at org.jboss.ws.core.jaxws.client.ClientImpl.invoke(ClientImpl.java:231)
    at org.jboss.ws.core.jaxws.client.ClientProxy.invoke(ClientProxy.java:171)
    at org.jboss.ws.core.jaxws.client.ClientProxy.invoke(ClientProxy.java:157)
    at $Proxy234.searchCustomerIdEquip(Unknown Source)

1 个答案:

答案 0 :(得分:3)

以下是我为解决问题所做的工作,

第一步

我将Solaris Java版本从版本1.6.0_23升级到版本1.6.0_27。从javax.xml.ws.soap.SOAPFaultException

升级更改例外
ERROR [org.jboss.ws.core.CommonClient] (ajp-10.1.75.243-8109-4) Exception caught while (preparing for) performing the invocation:
javax.xml.ws.soap.SOAPFaultException: Unqualified {http://schemas.xmlsoap.org/soap/envelope/}Client fault
    at org.jboss.ws.core.jaxws.SOAPFaultHelperJAXWS.getSOAPFaultException(SOAPFaultHelperJAXWS.java:85)
    at org.jboss.ws.core.jaxws.binding.SOAP11BindingJAXWS.throwFaultException(SOAP11BindingJAXWS.java:107)
    at org.jboss.ws.core.CommonSOAPBinding.unbindResponseMessage(CommonSOAPBinding.java:558)
    at org.jboss.ws.core.CommonClient.invoke(CommonClient.java:396)
    at org.jboss.ws.core.jaxws.client.ClientImpl.invoke(ClientImpl.java:231)
    at org.jboss.ws.core.jaxws.client.ClientProxy.invoke(ClientProxy.java:171)
    at org.jboss.ws.core.jaxws.client.ClientProxy.invoke(ClientProxy.java:157)

java.io.IOException ...

[org.jboss.ws.core.CommonClient] (ajp-10.1.75.243-8109-1) Exception caught while (preparing for) performing the invocation:
java.io.IOException: Could not transmit message
    at org.jboss.ws.core.client.HTTPRemotingConnection.invoke(HTTPRemotingConnection.java:253)
    at org.jboss.ws.core.client.SOAPProtocolConnectionHTTP.invoke(SOAPProtocolConnectionHTTP.java:71)
    at org.jboss.ws.core.CommonClient.invoke(CommonClient.java:360)
    at org.jboss.ws.core.jaxws.client.ClientImpl.invoke(ClientImpl.java:231)
    at org.jboss.ws.core.jaxws.client.ClientProxy.invoke(ClientProxy.java:171)
    at org.jboss.ws.core.jaxws.client.ClientProxy.invoke(ClientProxy.java:157)

第二步

获得IOException后,我意识到我们的负载均衡器可能不允许分块编码..所以我更改了Jboss配置,以便它不使用分块编码,编辑下面的文件..

jboss-eap-5.1.0.GA/jboss-as/server/<instance>/deployers/jbossws.deployer/META-INF/standard-jaxws-client-config.xml

..并将http://org.jboss.ws/http#chunksize2048设置为0

这样做了!我们不再有SOAPFaultException了。