org.apache.axis2.AxisFault:服务器localhost无法响应

时间:2012-11-29 11:36:48

标签: java tomcat axis2

我正在编写一个部署在tomcat上的web服务,当客户端调用webservice时,它设法成功发送信息,但当我应该得到回复时,我收到错误消息,如下面的控制台 我注意到tomcat崩溃并关闭,每次运行客户端我都要再次启动tomcat

at org.apache.axis2.AxisFault.makeFault(AxisFault.java:430)
at org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:203)
at org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:76)
at        org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessageWithCommons(CommonsHTTPTransportSender.java:400)
at org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:225)
at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:438)
at org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:402)
at org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:229)
at org.apache.axis2.client.OperationClient.execute(OperationClient.java:165)
at ws.test.WebserviceSTSStub.certificate(WebserviceSTSStub.java:184)
at client.Client.main(Client.java:144)
Caused by: org.apache.commons.httpclient.NoHttpResponseException: The server localhost failed to respond
at org.apache.commons.httpclient.HttpMethodBase.readStatusLine(HttpMethodBase.java:1976)
at org.apache.commons.httpclient.HttpMethodBase.readResponse(HttpMethodBase.java:1735)
at org.apache.commons.httpclient.HttpMethodBase.execute(HttpMethodBase.java:1098)
at org.apache.commons.httpclient.HttpMethodDirector.executeWithRetry(HttpMethodDirector.java:398)
at org.apache.commons.httpclient.HttpMethodDirector.executeMethod(HttpMethodDirector.java:171)
at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:397)
at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:346)
at org.apache.axis2.transport.http.AbstractHTTPSender.executeMethod(AbstractHTTPSender.java:560)
at org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:199)
... 9 more
Failed at communicating methods

这是tomcat的日志文件

Nov 29, 2012 3:26:44 PM org.apache.coyote.AbstractProtocol pause
INFO: Pausing ProtocolHandler ["http-apr-8080"]
Nov 29, 2012 3:26:44 PM org.apache.coyote.AbstractProtocol pause
INFO: Pausing ProtocolHandler ["ajp-apr-8009"]
Nov 29, 2012 3:26:44 PM org.apache.catalina.core.StandardService stopInternal
INFO: Stopping service Catalina
Nov 29, 2012 3:26:44 PM org.apache.catalina.core.StandardWrapper unload
INFO: Waiting for 1 instance(s) to be deallocated
Nov 29, 2012 3:26:45 PM org.apache.catalina.core.StandardWrapper unload
INFO: Waiting for 1 instance(s) to be deallocated
Nov 29, 2012 3:26:46 PM org.apache.catalina.core.StandardWrapper unload
INFO: Waiting for 1 instance(s) to be deallocated
Nov 29, 2012 3:26:47 PM org.apache.catalina.loader.WebappClassLoader         clearReferencesThreads
SEVERE: The web application [/axis2] is still processing a request that has yet to     finish. This is very likely to create a memory leak. You can control the time allowed for     requests to finish by using the unloadDelay attribute of the standard Context implementation.
Nov 29, 2012 3:26:47 PM org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks
SEVERE: The web application [/axis2] created a ThreadLocal with key of type [java.lang.ThreadLocal] (value [java.lang.ThreadLocal@1b3cbc9]) and a value of type [org.apache.axis2.context.MessageContext] (value [[MessageContext: logID=urn:uuid:81669E5CA369177A451354188407165]]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak.
Nov 29, 2012 3:26:47 PM org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks
SEVERE: The web application [/axis2] created a ThreadLocal with key of type [org.apache.xmlbeans.XmlBeans$1] (value [org.apache.xmlbeans.XmlBeans$1@1080026]) and a value of type [java.lang.ref.SoftReference] (value [java.lang.ref.SoftReference@41ca9a]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak.
Nov 29, 2012 3:26:47 PM org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks
SEVERE: The web application [/axis2] created a ThreadLocal with key of type [org.apache.xmlbeans.impl.store.CharUtil$1] (value [org.apache.xmlbeans.impl.store.CharUtil$1@15c4bc6]) and a value of type [java.lang.ref.SoftReference] (value [java.lang.ref.SoftReference@72b4dc]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak.
Nov 29, 2012 3:26:47 PM org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks
SEVERE: The web application [/axis2] created a ThreadLocal with key of type [org.apache.xmlbeans.impl.schema.SchemaTypeLoaderImpl$1] (value [org.apache.xmlbeans.impl.schema.SchemaTypeLoaderImpl$1@c001cd]) and a value of type [java.util.ArrayList] (value [[java.lang.ref.SoftReference@1b66f75]]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak.
Nov 29, 2012 3:26:47 PM org.apache.coyote.AbstractProtocol stop
INFO: Stopping ProtocolHandler ["http-apr-8080"]
Nov 29, 2012 3:26:47 PM org.apache.coyote.AbstractProtocol stop
INFO: Stopping ProtocolHandler ["ajp-apr-8009"]

我无法判断服务的逻辑是否已损坏,或者设置是否设置未正确完成但我得到的结果是该服务无法找到发送请求的客户端

这可能是由外部库引起的吗?我使用bouncycastle库,我刚刚放在webapps \ axis2 \ WEB-INF \ lib文件夹中

我在webapps \ axis2 \ WEB-INF \ classes中也有一个属性文件和一个jaas配置文件,我按如下方式访问

属性文件

Properties props = new Properties();
      props.load( new FileInputStream( "C:\\apache\\apache-tomcat-7.0.29\\webapps\\axis2\\WEB-INF\\classes\\server.properties"));

JAAS配置文件

System.setProperty( "java.security.auth.login.config", "C:\\apache\\apache-tomcat-7.0.29\\webapps\\axis2\\WEB-INF\\classes\\jaas.conf");

0 个答案:

没有答案