c3p0 and MySQL connection lost after 8 hours


最近、c 3 p 0データベース接続プールを使用し、接続プールの接続が翌日に「show processlist;検査中に全部切れた.
Applicationはsqlを実行すると、「communication failure with Mysql database」異常を報告します.
検索するとmysqlのデフォルトwait_が見つかりましたtimeoutは8時間で、c 3 p 0ではcheckout connection時に接続の有効性をチェックし、古い接続であれば、その接続をクリアし、新しい接続を確立することができます.
具体的な参考は以下の通りです.
1. http://www.mchange.com/projects/c3p0/index.html#configuring_connection_testing
2. http://jimlaren.iteye.com/blog/137103
3. http://osbi.nl/2009/09/pentaho-and-mysql-connection-lost-after-8-hours/
4. http://soft-app.iteye.com/blog/921828
最終的に選択したパラメータの組み合わせは
//set to 'SELECT 1'       
preferredTestQuery = 'SELECT 1'         
//set to something slightly less than wait_timeout, preventing 'stale' connections from being handed out    
maxIdleTime = 25000     
//if you can take the performance 'hit', set to "true"    
testConnectionOnCheckout = true  

しかし新しい異常が発見され、
08/Nov/2011 03:35:00, {com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread-#1} - DEBUG NewPooledConnection : com.mchange.v2.c3p0.impl.NewPooledConnection@41ab11b0 closed by a client
java.lang.Exception: DEBUG -- CLOSE BY CLIENT STACK TRAC
        at com.mchange.v2.c3p0.impl.NewPooledConnection.close(NewPooledConnection.java:566)

        at com.mchange.v2.c3p0.impl.NewPooledConnection.close(NewPooledConnection.java:234)

        at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool$1PooledConnectionResourcePoolManager.destroyResource(C3P0PooledConnectionPool.java:470)

        at com.mchange.v2.resourcepool.BasicResourcePool$1DestroyResourceTask.run(BasicResourcePool.java:964)

        at com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread.run(ThreadPoolAsynchronousRunner.java:547)


からhttp://forum.springsource.org/archive/index.php/t-47689.htmllog 4 jのレベルをDEBUGからINFOに変更すると異常は報告されないことがわかる.