See the SoftMinEvictableIdleTimeMillis property:
http://jakarta.apache.org/commons/pool/apidocs/org/apache/commons/pool/impl/GenericObjectPool.html#setSoftMinEvictableIdleTimeMillis(long)

On 2/13/07, Sharma, Siddharth <[EMAIL PROTECTED]> wrote:
Hi

I have written a wrapper API around commons-pool 1.3.
I have configured the pool with the following values:

max-idle-objects="10"
min-idle-objects="5"
max-active-objects="25"
time-between-eviction-runs-millis="60000"
min-evictable-idle-time-millis="30000"
test-object-on-borrow="true"
when-exhausted-action="2"

When there is absolutely no activity, there are 5 objects in the pool (since
that is configured to be the minimum).
The evictor thread does pool maintenance every minute. It removes all the
objects that are idle for 30 seconds; this means all 5 objects in the pool.
It removes them and then probably realizes that it needs to maintain minimum
5 objects in the pool and creates 5 new objects and pools them. Thus it
keeps churning every minute. Why does it remove those objects only to create
them back? Is this behavior configurable to first check "min-idle-objects"
and if it is at the minimum threshold, then not to actually evict and
recreate?

Thanks
Sidd



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




--
Sandy McArthur

"He who dares not offend cannot be honest."
- Thomas Paine

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to