On 5/9/11 11:28 AM, Stevo Slavić wrote: > I believe you're looking for minIdle configuration property. Find more > configuration details @ http://commons.apache.org/dbcp/configuration.html > One thing (as of this post) missing from the config doc above is that in order for the minIdle setting to have any effect, pool maintenance has to be enabled. To do that, you need to provide a positive value for timeBetweenEvictionRunsMillis. Attempts to ensure minIdle happen when the maintenance thread runs and they will never in any case cause more than maxActive connections to be under management by the pool. So, for example, if maxActive = 10, minIdle = 5 and when the maintenance thread runs 6 connections are checked out to clients, it will only be able to create 4 connections to load into the pool.
Phil > Regards, > Stevo. > > On May 9, 2011 8:23 PM, "Fernando O." <fot...@gmail.com> wrote: > > Hi all > I'm trying to migrate from C3p0 to dbcp and it looks like some (a lot > of?) things are different. one of the more important problems im facing is > that it looks like I can't specify a minimum amount of connections in the > pool. so if I run a kill test, after initializing the pool with say 10 > connections I see only 1 connection, no other connection gets created > > is there a way to get my 10 connections back without specifying > "autoreconnect " in the jdbc url? > --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscr...@commons.apache.org For additional commands, e-mail: user-h...@commons.apache.org