[英]Communication Link Failure MySQL
I am using hibernate with mysql database. 我正在将休眠与mysql数据库一起使用。 But I am getting an exception "Communication link failure" every morning.
但是每天早上我都会收到一个异常消息“通信链接失败”。
This could be due to idle connection whole night which MYSql closes in morning. 这可能是由于MYSql在早上关闭的整个晚上的空闲连接。
So what could be the best way to solve this problem. 因此,解决该问题的最佳方法是什么。 Should I increase wait_timeout or write a service which pings server every few hours?
我应该增加wait_timeout还是编写每隔几个小时ping服务器的服务? Please suggest.
请提出建议。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.