[jboss-jira] [JBoss JIRA] Updated: (EJBTHREE-1840) StrictMaxPool does not maintain a correct "inUse" count leading to incorrect reporting of "AvailableCount"
jaikiran pai (JIRA)
jira-events at lists.jboss.org
Mon Jun 1 06:31:56 EDT 2009
[ https://jira.jboss.org/jira/browse/EJBTHREE-1840?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
jaikiran pai updated EJBTHREE-1840:
-----------------------------------
Component/s: core
(was: pool)
> StrictMaxPool does not maintain a correct "inUse" count leading to incorrect reporting of "AvailableCount"
> ----------------------------------------------------------------------------------------------------------
>
> Key: EJBTHREE-1840
> URL: https://jira.jboss.org/jira/browse/EJBTHREE-1840
> Project: EJB 3.0
> Issue Type: Bug
> Components: core
> Affects Versions: 1.1.6
> Reporter: jaikiran pai
> Assignee: jaikiran pai
> Fix For: 1.1.7
>
>
> The org.jboss.ejb3.test.stateless.unit.MetricsUnitTestCase shows a failure w.r.t the "AvailableCount" of a bean marked with StrictMaxPool.
> The StrictMaxPool internally implements the getAvailableCount() as follows:
> public int getAvailableCount()
> {
> return maxSize - inUse;
> }
> The "inUse" count is handled incorrectly in the discard and remove method of this pool leading to that count reaching a negative value. Ultimately, this leads to incorrect available count being reported.
> When an exception occurs, the bean is discarded from the pool. This leads to a call on discard method of the StrictMaxPool which decrements the inUse count and then calls the remove method which *again* decrements the inUse count for the same bean context.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list