[ 
https://issues.apache.org/jira/browse/POOL-29?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Mark Thomas resolved POOL-29.
-----------------------------

    Resolution: Fixed

POOL-129 indicates the issue is with pool 1.3. In 1.3 addObjectToPool modifies 
_numActive outside of a sync block. This is the likely root cause of this 
problem. This was fixed as part of the fix for POOL-93.

> [pool]NumActive goes to negative when the pool can't create more objects
> ------------------------------------------------------------------------
>
>                 Key: POOL-29
>                 URL: https://issues.apache.org/jira/browse/POOL-29
>             Project: Commons Pool
>          Issue Type: Bug
>    Affects Versions: 1.2
>         Environment: Operating System: All
> Platform: All
>            Reporter: Daniel C. Amadei
>             Fix For: 1.5
>
>
> Under heavy usage on multithreaded environment, the pool start to show 
> NumActive property as negative value.
> We've implemented a pool of sockets and if there is a problem creating new 
> sockets after some time of successful operation, the pool starts trying to 
> create new sockets but while trying to create them, it goes removing invalid 
> instances from the pool and after the evictor runs, it starts to invalidate 
> the 
> objects, making the numActive property stay negative.
> I changed the class GenericObjectPoolImpl to check if _numActive property is 
> bigger than Zero, before decrementing it and I'd like to know if this is ok 
> so 
> I can submit a patch. From my tests, it's working fine after checking if 
> numActive is > than zero before executing numActive--.
> Daniel

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to