Hi John,

Ah, very nice.  That's exactly what I was looking for...  I don't
actually understand why you'd ever want the pool to get reset.  

Before, I actually had JDBC Connection Pooling set up using the
bitmechanic jdbcpool (http://www.bitmechanic.com/projects/jdbcpool/). 
However, I want to use the DataSource interface (or I guess the
ConnectionPoolDataSource interface) to get at my databases so that I can
set the loginTimout and a few other things that this new stuff
provides...  

Thanks for the pointer, I've just checked it out of CVS and will give it
a try.

Cheers,

Scott

On Mon, 2002-04-22 at 11:21, John McNally wrote:
> Hello Scott,
> 
> There is another connection pool located in commons-sandbox/jdbc2pool
> that behaves as you expect, multiple lookups of the same pool will NOT
> reset the pool.  Jdbc2pool is written to use a ConnectionPoolDataSource
> as the backend providing the connections.  It does have an adapter
> package that can be used with the older Driver style of providing
> physical connections.  This adapter adds the benefit of
> PreparedStatement pooling as well.  Jdbcpool has not been put to the
> test in a production system yet, but it does pass its tests and is based
> on the same commons-pool code used in BasicDataSource.
> 
> john mcnally
> 
> Scott Jones wrote:
> > 
> > Hi Chad,
> > 
> > Didn't get your emails until this morning -- are you experiencing the
> > same problems that I was talking about?  Basically, it seems like a new
> > connection pool is getting set up after every JNDI lookup (which I'd
> > basically like to do every time I run a query).   If I hold on to the
> > same datasource, I can see that it's obvious that connection pooling is
> > working...
> > 
> > I've just been doing something like the following the code below to test
> > it out.  However, the thing that I notice is that rerunning this code
> > doesn't hold on to the original pool -- in the following code segment
> > the first and second connections are always > 50ms to get and the last
> > one (which comes from the pool) is always around 0-1ms.  It seems to me
> > that the DataSource should get "cached" or held on to in some way --
> > Otherwise, it seems like it's defeating the purpose of connection
> > pooling!!!
> 
> --
> To unsubscribe:   <mailto:[EMAIL PROTECTED]>
> For additional commands: <mailto:[EMAIL PROTECTED]>
> Troubles with the list: <mailto:[EMAIL PROTECTED]>
-- 
Scott Jones
On-Site Manager, Inc.
[EMAIL PROTECTED]
8-ONSITEMGR (866-748-3647)

--
To unsubscribe:   <mailto:[EMAIL PROTECTED]>
For additional commands: <mailto:[EMAIL PROTECTED]>
Troubles with the list: <mailto:[EMAIL PROTECTED]>

Reply via email to