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 (Resolved) (JIRA)" <ji...@apache.org> on 2011/12/17 20:09:30 UTC

[jira] [Resolved] (POOL-205) GKOP - inconsistent synchronisation of poolKeyList

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

Mark Thomas resolved POOL-205.
------------------------------

    Resolution: Fixed

Fixed by adding a read lock
                
> GKOP - inconsistent synchronisation of poolKeyList
> --------------------------------------------------
>
>                 Key: POOL-205
>                 URL: https://issues.apache.org/jira/browse/POOL-205
>             Project: Commons Pool
>          Issue Type: Bug
>    Affects Versions: 2.0
>            Reporter: Sebb
>
> poolKeyList is an ArrayList - which is not thread-safe.
> Updates are performed whilst holding the keyLock.writeLock.
> However, the list is read in evict() without using the same lock, so there's a potential for evict() to see stale or inconsistent state.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira