开发者社区> 问答> 正文

jdbc-pool连接mysql自动断开的问题

大家好,在用jdbc-pool连接mysql的时候总是会出现类似:
The last packet successfully received from the server was 11,246 milliseconds ago. The last packet sent successfully to the server was 1 milliseconds ago.
以及
java.io.EOFException: Can not read response from server. Expected to read 4 bytes, read 0 bytes before connection was unexpectedly lost.
的问题。在网上找了很久,但是还是没有找到合适的解决方法。
我的配置如下:
5
mysql中的参数如:
4
请问,我要怎么去配置呢?谢谢!

展开
收起
落地花开啦 2016-02-26 13:52:31 2525 0
1 条回答
写回答
取消 提交回答
  • 喜欢技术,喜欢努力的人
    <property name="timeBetweenEvictionRunsMillis" value="3600000" />
    <property name="minEvictableIdleTimeMillis" value="120000" />
    <property name="removeAbandonedTimeout" value="6000000" />

    太大了

    2019-07-17 18:48:09
    赞同 展开评论 打赏
问答排行榜
最热
最新

相关电子书

更多
搭建电商项目架构连接MySQL 立即下载
搭建4层电商项目架构,实战连接MySQL 立即下载
PolarDB MySQL引擎重磅功能及产品能力盛大发布 立即下载

相关镜像