You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Phil Steitz (JIRA)" <ji...@apache.org> on 2015/08/15 01:08:46 UTC

[jira] [Commented] (POOL-301) Add interceptors to proxied pools

    [ https://issues.apache.org/jira/browse/POOL-301?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14697932#comment-14697932 ] 

Phil Steitz commented on POOL-301:
----------------------------------

A comment I forgot to add in the modification to BaseProxyHandler.   The setup there is not thread-safe.  If intercepted methods are concurrently executed on the same pooled object, the before and after methods may get interleaved.  Also, the interceptors themselves need to be threadsafe and able to handle interleaved invocation across pooled objects. 

> Add interceptors to proxied pools
> ---------------------------------
>
>                 Key: POOL-301
>                 URL: https://issues.apache.org/jira/browse/POOL-301
>             Project: Commons Pool
>          Issue Type: Improvement
>    Affects Versions: 2.0, 2.1, 2.2, 2.3
>            Reporter: Phil Steitz
>         Attachments: interceptors.patch
>
>
> The proxied pools in org.apache.commons.pool2.proxy have some built-in support for some method interceptor functions (e.g. calling use() to prevent reset abandoned timers for objects that implement UsageTracking).  Support might be added for configurable interceptors that could be user-supplied.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)