The last packet successfully received from the server was 667,342 milliseconds a

mysql的连接一直很2B,以前是过段时间会中断连接。

现在是一启动就报错。

主要的解决办法就是在连接池(我用的是Druid)上下功夫。

在连接时,它会有一个检测的配置:

大致如下:

testValiation=select 1

testOnBorrow=true

refurl:http://nkcoder.github.io/blog/20140712/mysql-reconnect-packet-lost/

猜你喜欢

转载自wandejun1012.iteye.com/blog/2212830
今日推荐