0 Replies Latest reply on Apr 16, 2012 10:26 AM by p100

    JBoss 5.1 StrictMaxPool ignored after exception

    p100

      Hi,

       

      I'm using annotation

      {code:java} @Pool(value = PoolDefaults.POOL_IMPLEMENTATION_STRICTMAX, maxSize = 1, timeout = 10000) {code}

      to implelement a singleton bean. It is working fine - concurrent calls to bean are blocked. But if exception occurs in bean method, the instance is discarded and new created instances seems to ignore max pool size setting. I can observer parallel execution of bean methods.

       

      It can be important that this singleton bean is called from other bean that is called with AsyncUtils.mixinAsync, so:

      Bean A calls bean B with AsyncUtils.mixinAsync

      Bean B call singleton bean C

      All components are stateless

       

      It is critical part of my solution, do you have some advice how to workaround this error?