Re: [c3p0-users] SQLException -- connection explicity closed
Status: Beta
Brought to you by:
swaldman
From: Steve W. <swa...@mc...> - 2006-11-06 20:38:36
|
Paul, Under what circumstances are you seeing this? Occasionally or frequently? What version of c3p0 are you using? The Exception you are seeing is one that indicates a normal close() of a c3p0 PooledConnection. It shouldn't be thrown or logged. (c3p0 keeps track of what Exception caused an Exception to be invalidated, if it is determined that a Connection is no longer suitable for pooling due to some error. The exception you're seeing is the "invalidating exception" that signals nothing went wrong, but the Connection was closed normally. It's not odd that this Connection is constructed, but odd that you should ever be seeing it. Reviewing this code a bit, the placeholder Exception is reconstructed on every PooledConnection close(), which it needn't be. In the future, the placeholder Exception will be a constant constructed during class initialization. (PooledConnections are close()ed relatively infrequently, so in real-world performance terms, the cost of the construction-on-close, as well as the benefit of the fix, are likely to be quite small.) Anyway, I don't know why you are seeing this get logged. That's the mystery. Please do let me know the version of c3p0 you're using (if possible send the version banner and config dump emitted on c3p0's initialization), and more specifics about when you see this get logged. smiles, Steve --- Steve Waldman Machinery For Change, Inc. On Nov 6, 2006, at 3:17 PM, Paul Ortiz wrote: > Does anyone know what might be causing this > SQLException? Does it have something to do > w/connection testing, misconfiguration? > > 12:06:19,277 INFO [[/WebPay]] java.sql.SQLException: > com.mchange.v2.c3p0.impl.NewPooledConnection@ab5809 > explicitly closed! > 12:06:19,277 INFO [[/WebPay]] at > com.mchange.v2.c3p0.impl.NewPooledConnection.close > (NewPooledConnection.java:484) > 12:06:19,277 INFO [[/WebPay]] at > com.mchange.v2.c3p0.impl.NewPooledConnection.close > (NewPooledConnection.java:187) > 12:06:19,277 INFO [[/WebPay]] at > com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool > $1PooledConnectionResourcePoolManager.destroyResource > (C3P0PooledConnectionPool.java:411) > 12:06:19,277 INFO [[/WebPay]] at > com.mchange.v2.resourcepool.BasicResourcePool > $1DestroyResourceTask.run(BasicResourcePool.java:812) > 12:06:19,277 INFO [[/WebPay]] at > com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread.run > (ThreadPoolAsynchronousRunner.java:547) > > My c3p0 config: > driverClass=oracle.jdbc.driver.OracleDriver > jdbcUrl=jdbc:oracle:thin:@xx.xx.x.xxx:1521:RAPID63 > user=user1 > password=password1 > acquireIncrement=1 > idleConnectionTestPeriod=100 > maxStatements=0 > maxPoolSize=25 > minPoolSize=1 > > Thank you. > > P. > > > > > ______________________________________________________________________ > ____________________ > Sponsored Link > > Talk more and pay less. Vonage can save you up to $300 a year on > your phone bill. > Sign up now. http://www.vonage.com/startsavingnow/ > > ---------------------------------------------------------------------- > --- > Using Tomcat but need to do more? Need to support web services, > security? > Get stuff done quickly with pre-integrated technology to make your > job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache > Geronimo > http://sel.as-us.falkag.net/sel? > cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > c3p0-users mailing list > c3p...@li... > https://lists.sourceforge.net/lists/listinfo/c3p0-users |