HikariCP icon indicating copy to clipboard operation
HikariCP copied to clipboard

KeepAlive setting for in-use/active connections

Open thunkWaltz opened this issue 2 years ago • 0 comments

We are using MySql behind ELB in AWS. ELB tends to have a idle timeout value, after which it resets the connection if no packet is seen in the period. Maximum value that could be set is 4000 seconds.

However MySql wait_timeout default is 8 hours. In our case sometimes transaction runs for hours and also there is no query issued for few hours. I was hoping HikariCP keepAlive would be able to take care of ELB timeout and transaction would not fail. But as mentioned in the documents it only works for idle or not in-use connections. Is there any other configuration parameter in Hikari or MySql Connector to achieve the same?

thunkWaltz avatar Oct 04 '21 02:10 thunkWaltz