服务器上跑了一个定时任务总会时不时的报出 WARN com.zaxxer.hikari.pool.PoolBase - HikariPool-1 - Failed to validate connection com.mysql.jdbc.JDBC4Connection@ccaeb43 (No operations allowed after connection closed.)
一般情况会连续报 10 次,然后获得连接,程序进行下去,偶尔会报一些 com.zaxxer.hikari.pool.ProxyConnection - HikariPool-1 - Connection com.mysql.jdbc.JDBC4Connection@6c65d404 marked as broken because of SQLSTATE(08007), ErrorCode(0)
然后就持续报错下去(拿不到连接)
maximum-pool-size: 50 minimum-idle: 20 validation-timeout: 5000 initial-size: 30
这是连接池的相关配置,请问如何调整合适呢?