java.net.SocketTimeoutException: Read timed out

java.net.SocketTimeoutException:Readtimedout

atjava.net.SocketInputStream.socketRead0(NativeMethod)

atjava.net.SocketInputStream.read(SocketInputStream.java:129)

atorg.apache.coyote.http11.InternalInputBuffer.fill(InternalInputBuffer.java:716)

atorg.apache.coyote.http11.InternalInputBuffer$InputStreamInputBuffer.doRead(InternalInputBuffer.java:746)

atorg.apache.coyote.http11.filters.IdentityInputFilter.doRead(IdentityInputFilter.java:116)

atorg.apache.coyote.http11.InternalInputBuffer.doRead(InternalInputBuffer.java:675)

atorg.apache.coyote.Request.doRead(Request.java:428)

atorg.apache.catalina.connector.InputBuffer.realReadBytes(InputBuffer.java:298)

atorg.apache.tomcat.util.buf.ByteChunk.substract(ByteChunk.java:372)

atorg.apache.catalina.connector.InputBuffer.readByte(InputBuffer.java:307)

atorg.apache.catalina.connector.CoyoteInputStream.read(CoyoteInputStream.java:105)

atcom.caucho.burlap.io.BurlapInput.read(BurlapInput.java:1527)

atcom.caucho.burlap.io.BurlapInput.skipWhitespace(BurlapInput.java:1493)

atcom.caucho.burlap.io.BurlapInput.parseTag(BurlapInput.java:1450)

atcom.caucho.burlap.io.BurlapInput.expectTag(BurlapInput.java:1432)

atcom.caucho.burlap.io.BurlapInput.startCall(BurlapInput.java:215)

atcom.caucho.burlap.server.BurlapSkeleton.invoke(BurlapSkeleton.java:170)

atnet.buffalo.spring.BuffaloServiceExporter.handleRequest(BuffaloServiceExporter.java:102)

atorg.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:44)

atorg.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:684)

atorg.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:625)

atorg.springframework.web.servlet.FrameworkServlet.serviceWrapper(FrameworkServlet.java:386)

atorg.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:355)

atjavax.servlet.http.HttpServlet.service(HttpServlet.java:710)

atjavax.servlet.http.HttpServlet.service(HttpServlet.java:803)

atorg.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)

atorg.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

atorg.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:172)

atorg.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)

atorg.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

atorg.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

atorg.xcesium.util.servlet.ServletFilter.doFilter(ServletFilter.java:28)

atorg.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

atorg.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

atorg.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)

atorg.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)

atorg.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)

atorg.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)

atorg.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)

atorg.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)

atorg.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)

atorg.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)

atorg.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)

atjava.lang.Thread.run(Thread.java:619)

这个是在socket编程时设置了超时,客户端没有在限定的时间内将数据发送的服务器,服务器为了保证服务性能,认定那个连接已经死掉了,就出现上述异常。

解决办法:

在存根业务调用代码中进行设置,添加:

_operationClient.getOptions().setTimeOutInMilliSeconds(600000L);

_operationClient表示一个客户端对象。

这个设置很不合理,但是没办法了,暂时先解决了问题再研究去。

http://blog.sina.com.cn/s/blog_5f042e930100deqj.html原文

相关推荐