java.net.SocketException:无效的请求:无效的方式

前端之家收集整理的这篇文章主要介绍了java.net.SocketException:无效的请求:无效的方式前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
我有一个在Google App Engine上运行的应用程序,它是 Android应用程序的后端.它基本上是Android应用程序和在我自己的服务器上运行的MysqL数据库之间的桥梁.

App Engine应用程序的日志中填写了有关断开连接时捕获的异常的警告.异常消息是java.net.SocketException:无效的请求:无效的方式.这对我没什么意义.

堆栈跟踪似乎表明此行是原因:mConnection.close(); (mConnection是一个java.sql.Connection对象).

除了日志中的警告,一切似乎都正常.可能导致此消息的原因是什么?

以下是带有堆栈跟踪的完整日志消息:

10:41:05.477
[s~appname/1.389899266979631246].<stderr>: Mon Jan 11 18:41:05 UTC 2016 WARN: Caught while disconnecting...

EXCEPTION STACK TRACE:



** BEGIN NESTED EXCEPTION ** 

java.net.SocketException
MESSAGE: Invalid request: Invalid how.

STACKTRACE:

java.net.SocketException: Invalid request: Invalid how.
    at com.google.appengine.api.socket.SocketApiHelper.translateError(SocketApiHelper.java:110)
    at com.google.appengine.api.socket.SocketApiHelper.translateError(SocketApiHelper.java:119)
    at com.google.appengine.api.socket.SocketApiHelper.makeSyncCall(SocketApiHelper.java:85)
    at com.google.appengine.api.socket.AppEngineSocketImpl.shutdownInput(AppEngineSocketImpl.java:664)
    at java.net.Socket.shutdownInput(Socket.java:1514)
    at com.MysqL.jdbc.MysqLIO.quit(MysqLIO.java:2184)
    at com.MysqL.jdbc.ConnectionImpl.realClose(ConnectionImpl.java:4451)
    at com.MysqL.jdbc.ConnectionImpl.close(ConnectionImpl.java:1599)
    at com.appname.backend.DatabaseHelper.close(DatabaseHelper.java:71)
    at com.appname.backend.SyncEndpoint.confirm(SyncEndpoint.java:191)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:606)
    at com.google.apphosting.runtime.security.shared.intercept.java.lang.reflect.Method_$1.run(Method_.java:171)
    at java.security.AccessController.doPrivileged(Native Method)
    at com.google.apphosting.runtime.security.shared.intercept.java.lang.reflect.Method_.privilegedInvoke(Method_.java:167)
    at com.google.apphosting.runtime.security.shared.intercept.java.lang.reflect.Method_.invoke_(Method_.java:125)
    at com.google.apphosting.runtime.security.shared.intercept.java.lang.reflect.Method_.invoke(Method_.java:44)
    at com.google.api.server.spi.SystemService.invokeServiceMethod(SystemService.java:363)
    at com.google.api.server.spi.SystemServiceServlet.execute(SystemServiceServlet.java:113)
    at com.google.api.server.spi.SystemServiceServlet.doPost(SystemServiceServlet.java:71)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
    at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1166)
    at com.google.apphosting.utils.servlet.ParseBlobUploadFilter.doFilter(ParseBlobUploadFilter.java:125)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)
    at com.google.apphosting.runtime.jetty.SaveSessionFilter.doFilter(SaveSessionFilter.java:37)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)
    at com.google.apphosting.utils.servlet.JdbcMysqLConnectionCleanupFilter.doFilter(JdbcMysqLConnectionCleanupFilter.java:60)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)
    at com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter(TransactionCleanupFilter.java:43)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)
    at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:388)
    at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
    at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
    at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
    at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:418)
    at com.google.apphosting.runtime.jetty.AppVersionHandlerMap.handle(AppVersionHandlerMap.java:260)
    at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
    at org.mortbay.jetty.Server.handle(Server.java:326)
    at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
    at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:923)
    at com.google.apphosting.runtime.jetty.RpcRequestParser.parseAvailable(RpcRequestParser.java:78)
    at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
    at com.google.apphosting.runtime.jetty.JettyServletEngineAdapter.serviceRequest(JettyServletEngineAdapter.java:148)
    at com.google.apphosting.runtime.JavaRuntime$RequestRunnable.run(JavaRuntime.java:469)
    at com.google.tracing.TraceContext$TraceContextRunnable.runInContext(TraceContext.java:437)
    at com.google.tracing.TraceContext$TraceContextRunnable$1.run(TraceContext.java:444)
    at com.google.tracing.CurrentContext.runInContext(CurrentContext.java:256)
    at com.google.tracing.TraceContext$AbstractTraceContextCallback.runInInheritedContextNoUnref(TraceContext.java:308)
    at com.google.tracing.TraceContext$AbstractTraceContextCallback.runInInheritedContext(TraceContext.java:300)
    at com.google.tracing.TraceContext$TraceContextRunnable.run(TraceContext.java:441)
    at com.google.apphosting.runtime.ThreadGroupPool$PoolEntry.run(ThreadGroupPool.java:235)
    at java.lang.Thread.run(Thread.java:745)


** END NESTED EXCEPTION **

解决方法

此问题似乎已由Google解决.以下是他们的回复

Thanks I believe the issue should be resolved,this was an old bug that has been fixed recently. Please reopen if you do see the issue recur.

来自:https://code.google.com/p/googleappengine/issues/detail?id=12664

猜你在找的Java相关文章