tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Caldarale, Charles R" <>
Subject RE: PooledConnection.getConnection - Tomcat JDBC Pool
Date Tue, 25 Mar 2014 20:16:39 GMT
> From: Christopher Schultz [] 
> Subject: Re: PooledConnection.getConnection - Tomcat JDBC Pool

> On 3/25/14, 10:53 AM, Pierce, Jonathan D wrote:
> > In the Aries class, the expectation is that 
> > XAConnection.getConnection().close() will return the connection to 
> > the pool, and that XAConnection.close() would close the physical 
> > connection.

> That sounds counter intuitive to me.

Agreed.  The application should have no knowledge of or concern with the physical connections.

> What's odd is that PooledConnection.getConnection() is documented to
> return a discardable wrapper of the current connection object. That's
> unexpected as far as I'm concerned.

No, an instance of PooledConnection is the so-called physical connection object.  Note that
PooledConnection is not to be used by the application, but rather only by the pool manager
to get connections from the JDBC driver.  No application writer should be looking at the PooledConnection
interface - it is of no interest to the app.

 - Chuck

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message