scear1992
Ohyes陈陈
2016-12-19 16:03
采纳率: 100%
浏览 6.6k
已采纳

阿里巴巴连接池断开连接

环境:spring spring mvc mybatis的maven项目。

问题:使用阿里巴巴连接池、登录后如果不去操作等待5分钟的样子就会报错如下:

23:28:14.801 [Druid-ConnectionPool-Destroy-1512369669] ERROR com.alibaba.druid.util.JdbcUtils - close connection error
java.sql.SQLRecoverableException: IO 错误: Software caused connection abort: recv failed
at oracle.jdbc.driver.T4CConnection.logoff(T4CConnection.java:504) ~[ojdbc6-11.2.jar:11.2.0.1.0]
at oracle.jdbc.driver.PhysicalConnection.close(PhysicalConnection.java:3754) ~[ojdbc6-11.2.jar:11.2.0.1.0]
at com.alibaba.druid.filter.FilterChainImpl.connection_close(FilterChainImpl.java:169) ~[druid-1.0.20.jar:1.0.20]
at com.alibaba.druid.filter.stat.StatFilter.connection_close(StatFilter.java:254) ~[druid-1.0.20.jar:1.0.20]
at com.alibaba.druid.filter.FilterChainImpl.connection_close(FilterChainImpl.java:165) ~[druid-1.0.20.jar:1.0.20]
at com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl.close(ConnectionProxyImpl.java:115) ~[druid-1.0.20.jar:1.0.20]
at com.alibaba.druid.util.JdbcUtils.close(JdbcUtils.java:83) ~[druid-1.0.20.jar:1.0.20]
at com.alibaba.druid.pool.DruidDataSource.shrink(DruidDataSource.java:2297) [druid-1.0.20.jar:1.0.20]
at com.alibaba.druid.pool.DruidDataSource$DestroyTask.run(DruidDataSource.java:2084) [druid-1.0.20.jar:1.0.20]
at com.alibaba.druid.pool.DruidDataSource$DestroyConnectionThread.run(DruidDataSource.java:2071) [druid-1.0.20.jar:1.0.20]
Caused by: java.net.SocketException: Software caused connection abort: recv failed
at java.net.SocketInputStream.socketRead0(Native Method) ~[na:1.7.0_67]
at java.net.SocketInputStream.read(SocketInputStream.java:152) ~[na:1.7.0_67]
at java.net.SocketInputStream.read(SocketInputStream.java:122) ~[na:1.7.0_67]
at oracle.net.ns.Packet.receive(Packet.java:282) ~[ojdbc6-11.2.jar:11.2.0.1.0]
at oracle.net.ns.DataPacket.receive(DataPacket.java:103) ~[ojdbc6-11.2.jar:11.2.0.1.0]
at oracle.net.ns.NetInputStream.getNextPacket(NetInputStream.java:230) ~[ojdbc6-11.2.jar:11.2.0.1.0]
at oracle.net.ns.NetInputStream.read(NetInputStream.java:175) ~[ojdbc6-11.2.jar:11.2.0.1.0]
at oracle.net.ns.NetInputStream.read(NetInputStream.java:100) ~[ojdbc6-11.2.jar:11.2.0.1.0]
at oracle.net.ns.NetInputStream.read(NetInputStream.java:85) ~[ojdbc6-11.2.jar:11.2.0.1.0]
at oracle.jdbc.driver.T4CSocketInputStreamWrapper.readNextPacket(T4CSocketInputStreamWrapper.java:122) ~[ojdbc6-11.2.jar:11.2.0.1.0]
at oracle.jdbc.driver.T4CSocketInputStreamWrapper.read(T4CSocketInputStreamWrapper.java:78) ~[ojdbc6-11.2.jar:11.2.0.1.0]
at oracle.jdbc.driver.T4CMAREngine.unmarshalUB1(T4CMAREngine.java:1179) ~[ojdbc6-11.2.jar:11.2.0.1.0]
at oracle.jdbc.driver.T4CMAREngine.unmarshalSB1(T4CMAREngine.java:1155) ~[ojdbc6-11.2.jar:11.2.0.1.0]
at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:279) ~[ojdbc6-11.2.jar:11.2.0.1.0]
at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:186) ~[ojdbc6-11.2.jar:11.2.0.1.0]
at oracle.jdbc.driver.T4C7Ocommoncall.doOLOGOFF(T4C7Ocommoncall.java:61) ~[ojdbc6-11.2.jar:11.2.0.1.0]
at oracle.jdbc.driver.T4CConnection.logoff(T4CConnection.java:491) ~[ojdbc6-11.2.jar:11.2.0.1.0]
... 9 common frames omitted

然后继续使用如果登录还未失效就会等很久才响应、页面才加载出来。​
数据库使用的:oracle
配置如下:










请问有人知道怎么回事吗?

  • 点赞
  • 写回答
  • 关注问题
  • 收藏
  • 邀请回答

2条回答 默认 最新

  • devmiao
    devmiao 2016-12-19 16:47
    已采纳
    点赞 评论
  • JE_GE
    JE_GE 2017-01-02 15:54

    多添加一下连接池的属性

    点赞 评论

相关推荐