Ok I just have confirmed that there is a problem with C3P0 when
I make several save and update operations, at first application becomes really slow then it stops working:
Following is the last log entries made before it crashes the application:
It enters in a loop that never ends
Code:
2006-10-06 18:57:48,234 DEBUG [http-8080-Processor23] resourcepool.BasicResourcePool (BasicResourcePool.java:1474) - trace com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1 [managed: 48, unused: 0, excluded: 0] (e.g. com.mchange.v2.c3p0.impl.NewPooledConnection@9ed5d6)
2006-10-06 18:57:48,250 DEBUG [http-8080-Processor23] resourcepool.BasicResourcePool (BasicResourcePool.java:1131) - awaitAvailable(): com.mchange.v2.c3p0.impl.NewPooledConnection@9ed5d6
2006-10-06 18:57:48,250 DEBUG [http-8080-Processor23] resourcepool.BasicResourcePool (BasicResourcePool.java:1474) - trace com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1 [managed: 48, unused: 0, excluded: 0] (e.g. com.mchange.v2.c3p0.impl.NewPooledConnection@9ed5d6)
2006-10-06 18:57:48,390 DEBUG [com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread-#2] impl.C3P0PooledConnectionPool$1PooledConnectionResourcePoolManager (C3P0PooledConnectionPool.java:195) - com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool$1PooledConnectionResourcePoolManager@1a462c9.acquireResource() returning.
2006-10-06 18:57:48,390 DEBUG [com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread-#2] resourcepool.BasicResourcePool (BasicResourcePool.java:1474) - trace com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1 [managed: 49, unused: 1, excluded: 0] (e.g. com.mchange.v2.c3p0.impl.NewPooledConnection@9ed5d6)
2006-10-06 18:57:48,390 DEBUG [http-8080-Processor23] impl.C3P0PooledConnectionPool$1PooledConnectionResourcePoolManager (C3P0PooledConnectionPool.java:270) - Testing PooledConnection [com.mchange.v2.c3p0.impl.NewPooledConnection@13bef50] on CHECKOUT.
2006-10-06 18:57:48,390 DEBUG [http-8080-Processor23] impl.C3P0PooledConnectionPool$1PooledConnectionResourcePoolManager (C3P0PooledConnectionPool.java:274) - Test of PooledConnection [com.mchange.v2.c3p0.impl.NewPooledConnection@13bef50] on CHECKOUT has SUCCEEDED.
2006-10-06 18:57:48,390 DEBUG [http-8080-Processor23] resourcepool.BasicResourcePool (BasicResourcePool.java:1474) - trace com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1 [managed: 49, unused: 0, excluded: 0] (e.g. com.mchange.v2.c3p0.impl.NewPooledConnection@9ed5d6)
2006-10-06 18:57:48,406 DEBUG [http-8080-Processor23] resourcepool.BasicResourcePool (BasicResourcePool.java:1131) - awaitAvailable(): com.mchange.v2.c3p0.impl.NewPooledConnection@9ed5d6
2006-10-06 18:57:48,406 DEBUG [http-8080-Processor23] resourcepool.BasicResourcePool (BasicResourcePool.java:1474) - trace com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1 [managed: 49, unused: 0, excluded: 0] (e.g. com.mchange.v2.c3p0.impl.NewPooledConnection@9ed5d6)
2006-10-06 18:57:49,062 DEBUG [com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread-#1] impl.C3P0PooledConnectionPool$1PooledConnectionResourcePoolManager (C3P0PooledConnectionPool.java:195) - com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool$1PooledConnectionResourcePoolManager@1a462c9.acquireResource() returning.
2006-10-06 18:57:49,062 DEBUG [com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread-#1] resourcepool.BasicResourcePool (BasicResourcePool.java:1474) - trace com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1 [managed: 50, unused: 1, excluded: 0] (e.g. com.mchange.v2.c3p0.impl.NewPooledConnection@9ed5d6)
2006-10-06 18:57:49,062 DEBUG [http-8080-Processor23] impl.C3P0PooledConnectionPool$1PooledConnectionResourcePoolManager (C3P0PooledConnectionPool.java:270) - Testing PooledConnection [com.mchange.v2.c3p0.impl.NewPooledConnection@1a0df30] on CHECKOUT.
2006-10-06 18:57:49,078 DEBUG [http-8080-Processor23] impl.C3P0PooledConnectionPool$1PooledConnectionResourcePoolManager (C3P0PooledConnectionPool.java:274) - Test of PooledConnection [com.mchange.v2.c3p0.impl.NewPooledConnection@1a0df30] on CHECKOUT has SUCCEEDED.
2006-10-06 18:57:49,078 DEBUG [http-8080-Processor23] resourcepool.BasicResourcePool (BasicResourcePool.java:1474) - trace com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1 [managed: 50, unused: 0, excluded: 0] (e.g. com.mchange.v2.c3p0.impl.NewPooledConnection@9ed5d6)
2006-10-06 18:57:49,078 DEBUG [http-8080-Processor23] resourcepool.BasicResourcePool (BasicResourcePool.java:1131) - awaitAvailable(): com.mchange.v2.c3p0.impl.NewPooledConnection@9ed5d6
2006-10-06 18:57:49,078 DEBUG [http-8080-Processor23] resourcepool.BasicResourcePool (BasicResourcePool.java:1474) - trace com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1 [managed: 50, unused: 0, excluded: 0] (e.g. com.mchange.v2.c3p0.impl.NewPooledConnection@9ed5d6)
2006-10-06 18:58:04,265 DEBUG [Timer-0] resourcepool.BasicResourcePool$CullTask (BasicResourcePool.java:1645) - Checking for expired resources - Fri Oct 06 18:58:04 GMT-05:00 2006 [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 18:58:04,265 DEBUG [Timer-0] resourcepool.BasicResourcePool (BasicResourcePool.java:1287) - BEGIN check for expired resources. [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 18:58:04,265 DEBUG [Timer-0] resourcepool.BasicResourcePool (BasicResourcePool.java:1308) - FINISHED check for expired resources. [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 18:58:29,265 DEBUG [Timer-0] resourcepool.BasicResourcePool$CullTask (BasicResourcePool.java:1645) - Checking for expired resources - Fri Oct 06 18:58:29 GMT-05:00 2006 [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 18:58:29,265 DEBUG [Timer-0] resourcepool.BasicResourcePool (BasicResourcePool.java:1287) - BEGIN check for expired resources. [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 18:58:29,265 DEBUG [Timer-0] resourcepool.BasicResourcePool (BasicResourcePool.java:1308) - FINISHED check for expired resources. [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 18:58:54,296 DEBUG [Timer-0] resourcepool.BasicResourcePool$CullTask (BasicResourcePool.java:1645) - Checking for expired resources - Fri Oct 06 18:58:54 GMT-05:00 2006 [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 18:58:54,296 DEBUG [Timer-0] resourcepool.BasicResourcePool (BasicResourcePool.java:1287) - BEGIN check for expired resources. [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 18:58:54,296 DEBUG [Timer-0] resourcepool.BasicResourcePool (BasicResourcePool.java:1308) - FINISHED check for expired resources. [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 18:59:19,265 DEBUG [Timer-0] resourcepool.BasicResourcePool$CullTask (BasicResourcePool.java:1645) - Checking for expired resources - Fri Oct 06 18:59:19 GMT-05:00 2006 [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 18:59:19,265 DEBUG [Timer-0] resourcepool.BasicResourcePool (BasicResourcePool.java:1287) - BEGIN check for expired resources. [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 18:59:19,265 DEBUG [Timer-0] resourcepool.BasicResourcePool (BasicResourcePool.java:1308) - FINISHED check for expired resources. [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 18:59:44,265 DEBUG [Timer-0] resourcepool.BasicResourcePool$CullTask (BasicResourcePool.java:1645) - Checking for expired resources - Fri Oct 06 18:59:44 GMT-05:00 2006 [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 18:59:44,265 DEBUG [Timer-0] resourcepool.BasicResourcePool (BasicResourcePool.java:1287) - BEGIN check for expired resources. [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 18:59:44,265 DEBUG [Timer-0] resourcepool.BasicResourcePool (BasicResourcePool.java:1308) - FINISHED check for expired resources. [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 19:00:09,296 DEBUG [Timer-0] resourcepool.BasicResourcePool$CullTask (BasicResourcePool.java:1645) - Checking for expired resources - Fri Oct 06 19:00:09 GMT-05:00 2006 [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 19:00:09,296 DEBUG [Timer-0] resourcepool.BasicResourcePool (BasicResourcePool.java:1287) - BEGIN check for expired resources. [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 19:00:09,296 DEBUG [Timer-0] resourcepool.BasicResourcePool (BasicResourcePool.java:1308) - FINISHED check for expired resources. [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 19:00:34,296 DEBUG [Timer-0] resourcepool.BasicResourcePool$CullTask (BasicResourcePool.java:1645) - Checking for expired resources - Fri Oct 06 19:00:34 GMT-05:00 2006 [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 19:00:34,296 DEBUG [Timer-0] resourcepool.BasicResourcePool (BasicResourcePool.java:1287) - BEGIN check for expired resources. [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 19:00:34,296 DEBUG [Timer-0] resourcepool.BasicResourcePool (BasicResourcePool.java:1308) - FINISHED check for expired resources. [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 19:00:59,296 DEBUG [Timer-0] resourcepool.BasicResourcePool$CullTask (BasicResourcePool.java:1645) - Checking for expired resources - Fri Oct 06 19:00:59 GMT-05:00 2006 [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 19:00:59,296 DEBUG [Timer-0] resourcepool.BasicResourcePool (BasicResourcePool.java:1287) - BEGIN check for expired resources. [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
2006-10-06 19:00:59,296 DEBUG [Timer-0] resourcepool.BasicResourcePool (BasicResourcePool.java:1308) - FINISHED check for expired resources. [com.mchange.v2.resourcepool.BasicResourcePool@b3a5d1]
Current c3p0 set up:
Code:
hibernate-config.xml
<property name="hibernate.c3p0.min_size">5</property>
<property name="hibernate.c3p0.max_size">50</property>
<property name="hibernate.c3p0.idle_test_period">300</property>
<property name="hibernate.c3p0.max_statements">0</property>
<property name="hibernate.c3p0.acquire_increment">3</property>
<property name="hibernate.c3p0.timeout">100</property>
c3p0.properties
c3p0.preferredTestQuery=SELECT 1 from dual
c3p0.maxConnectionAge=3600
c3p0.testConnectionOnCheckout=true
c3p0.acquireRetryDelay=1000
c3p0.acquireRetryAttempts=30
c3p0.breakAfterAcquireFailure=false
If someone has an idea I will apreciate it
regards