java.net.SocketException:管道损坏
我从我的应用程序服务器获取所有数据库连接的信息..
此异常发生了几个小时,然后自行修复。
与应用程序服务器的网络连接有关吗?
java.net.SocketException: Broken pipe com.inet.tds.SQLException: java.net.SocketException: Broken pipe java.net.SocketException: Broken pipe at java.net.SocketOutputStream.socketWrite0(Native Method) at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92) at java.net.SocketOutputStream.write(SocketOutputStream.java:136) at com.inet.tds.a.a(Unknown Source) at com.inet.tds.a.a(Unknown Source) at com.inet.tds.a.commit(Unknown Source) at com.inet.pool.a.commit(Unknown Source)
I am getting this for all the database connections from my app server..
This exception occured for couple of hours, then got fixed by itself.
Something to do with network connection from the appserver?
java.net.SocketException: Broken pipe com.inet.tds.SQLException: java.net.SocketException: Broken pipe java.net.SocketException: Broken pipe at java.net.SocketOutputStream.socketWrite0(Native Method) at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92) at java.net.SocketOutputStream.write(SocketOutputStream.java:136) at com.inet.tds.a.a(Unknown Source) at com.inet.tds.a.a(Unknown Source) at com.inet.tds.a.commit(Unknown Source) at com.inet.pool.a.commit(Unknown Source)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
对于MySQL,“默认情况下,如果没有发生任何事情,服务器会在八小时后关闭连接。” 并且,MySQL具有重连功能,支持在客户端检测到关闭连接后自动重连。
八小时? 通过使用连接池或长时间运行的后台作业,这是可能的。
http://dev.mysql.com/doc/refman/ 5.0/en/gone-away.html
For MySQL, "By default, the server closes the connection after eight hours if nothing has happened." And, MySQL has a reconnect feature that supports auto-reconnect after the closed connection is detected on the client side.
Eight hours? With the use of connection pooling or a long-running background job, that is possible.
http://dev.mysql.com/doc/refman/5.0/en/gone-away.html
在写入期间,连接被切断,这可能是由于目标关闭连接或目标进程已终止。 这不是您的实施错误。
During a write the connection was severed, this can be due the the destination closing the connection or the destination process has terminated. Its not an error with your implementation.
这意味着您的客户端已与服务器断开连接; 检查它是否正在运行。 参见此处
It means you client has disconnected from the server; check if it is running. See here