You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Mark Thomas (JIRA)" <ji...@apache.org> on 2009/11/01 17:37:59 UTC

[jira] Resolved: (POOL-152) GenericObjectPool hangs forever in borrowObject when newly created object is not validated

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

Mark Thomas resolved POOL-152.
------------------------------

       Resolution: Fixed
    Fix Version/s: 1.5.4

Thanks for the report. This has now been fixed in trunk.

That patch wasn't quite right - allocate() still needs to be called since the internal processing count has changed and that may allow another object to be allocated. GenericKeyedObjectPool also needed a similar fix and I also added a test case.

> GenericObjectPool hangs forever in borrowObject when newly created object is not validated
> ------------------------------------------------------------------------------------------
>
>                 Key: POOL-152
>                 URL: https://issues.apache.org/jira/browse/POOL-152
>             Project: Commons Pool
>          Issue Type: Bug
>    Affects Versions: 1.5.2, 1.5.3
>            Reporter: Bushov Alexander
>             Fix For: 1.5.4
>
>         Attachments: borrowObject.patch, Test.java
>
>
> If your set GenericObjectPool parameters such as: maxActive = 1 and whenExhaustedAction to block, testOnBorrow to true, call borrowObject that fails in validation of newly created object then second call of borrowObject will stuck.

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