This is because the waiting time for the connection configured in your connection pool is too long,mysqlThe connection has been considered expired. The solution is as follows
1. Modify my.cnf to extend the connection timeout [mysqld] wait_timeout=31536000 interactive_timeout=31536000
2. Add parameters to the connection URL autoReconnect=true&failOverReadOnly=false
In addition to the settings above, you can set how many seconds to go to the database to select 1 to keep this link alive
This is because the waiting time for the connection configured in your connection pool is too long,
mysql
The connection has been considered expired.The solution is as follows
1. Modify my.cnf to extend the connection timeout
[mysqld]
wait_timeout=31536000
interactive_timeout=31536000
2. Add parameters to the connection URL
autoReconnect=true&failOverReadOnly=false