commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mehul mehta <majidme...@hotmail.com>
Subject RE: [dbcp] Re: DBCP minIdle
Date Sat, 19 Jun 2010 21:59:41 GMT

Here is our config:
  maxActive="10000" maxWait="60000" minIdle="25" maxIdle="50" 
        validationQuery="select current_date from sysibm/sysdummy1" 
        testOnBorrow="true" 
        testWhileIdle="false" 
        testOnReturn="true" 
        timeBetweenEvictionRunsMillis="5000" 
        minEvictableIdleTimeMillis="60000" 
        numTestsPerEvictionRun="5" 
        removeAbandoned="true" 
        removeAbandonedTimeout="300" 
        logAbandoned="true"
It appears that our minEvictableIdleTimeMillis is too short. Probably, we should set it to
the default which is 30 minutes.
Also, is there any down side of setting timeBetweenEvictionRunsMillis to -1 (no evictor)?
Not sure if you observe any thing else in the config that can cause performance issues?
Thanks,
- Mehul

> Date: Sat, 19 Jun 2010 12:45:31 -0400
> From: phil.steitz@gmail.com
> To: user@commons.apache.org
> Subject: [dbcp] Re: DBCP minIdle
> 
> mehul mehta wrote:
> > 
> > Hello, We have dbcp configuration in production set as minIdle = 25, maxIdle = 50,
maxActive = 10000. We often experience slow down in queries to the database that normally
do not take that long. We are pretty sure that it is not the database.Let us say the idle
connections are 25. Now one of the idle connections is used up. Does dbcp create a new connection
right away to maintain 25 idle connections. Or does dbcp wait for 25 idle connections to be
used up and then create 25 new connections at one time? Regards,
> 
> The pool does not attempt to ensure minIdle after each
> borrow/return. It does this each time the "evictor" maintenance
> thread runs, which is once every timeBetweenEvictionRunsMillis
> milliseconds.
> 
> maxIdle is enforced on each return to the pool - i.e., if there are
> maxIdle connections idle in the pool when a connection is returned,
> it is destroyed.
> 
> What versions of dbcp and pool are you running and what is your
> timeBetweenEvictionRunsMillis setting?
> 
> Phil
> 
> > - Mehul 		 	   		  
> > _________________________________________________________________
> > See the news as it happens on MSN videos
> > http://video.in.msn.com/
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@commons.apache.org
> For additional commands, e-mail: user-help@commons.apache.org
> 
 		 	   		  
_________________________________________________________________
The latest in fashion and style in MSN Lifestyle
http://lifestyle.in.msn.com/
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message