我的应用程序在使用Hibernate与MySQL数据库交谈时偶尔会看到此异常.我尝试调整C3p0属性但它似乎不起作用.
以下是C3p0相关设置:
2
60
2
10
0
180
select 1
连接网址如下所示:
jdbc:mysql://?autoReconnect=true&useUniCode=true&characterEncoding=UTF-8&useSSL=true&requireSSL=true&verifyServerCertificate=false
Stacktrace是:
com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure
Last packet sent to the server was 1549998 ms ago.
Caused by: javax.net.ssl.SSLException: Connection has been shutdown: javax.net.ssl.SSLException: java.net.SocketException:
Connection reset
我需要调整MySQL系统变量吗?任何指针如何才能避免这种异常?
谢谢
Jitendra