[
https://jira.jboss.org/jira/browse/JBCLUSTER-244?page=com.atlassian.jira....
]
Brian Stansberry moved JBAS-7522 to JBCLUSTER-244:
--------------------------------------------------
Project: JBoss Clustering (was: JBoss Application Server)
Key: JBCLUSTER-244 (was: JBAS-7522)
Component/s: HA-Server-Cache-JBC
(was: Web (Tomcat) service)
(was: Clustering)
Fix Version/s: HA-Server-Cache-JBC 2.1.1.GA
(was: JBossAS-6.0.0.M2)
JBossCacheManager obtains Cache reference prematurely
-----------------------------------------------------
Key: JBCLUSTER-244
URL:
https://jira.jboss.org/jira/browse/JBCLUSTER-244
Project: JBoss Clustering
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: HA-Server-Cache-JBC
Reporter: Brian Stansberry
Assignee: Brian Stansberry
Fix For: HA-Server-Cache-JBC 2.1.1.GA
JBossCacheManager ends up acquiring a reference to the JBC cache during it's init
method. This is done to allow throwing of ClusteringNotSupportedException by that method,
allowing the behavior whereby a the deployment of a <distributable/> webapp in the
default config can detect the absence of clustering classes and fall back on the
non-clustered StandardManager.
The problem here is JBossContextConfig can end up creating > 1 JBossCacheManager
instance and calling init on it. (Need to investigate if that can be avoided.) If a 2nd
instance is created, stop is not called on the first (since it's never been started).
But the cache has been obtained from the CacheManager, increasing the reference count for
the cache. Effect is the cache never gets fully released.
This is the cause of recent failures in trunk of
(AttributeBased)SessionPassivationUnitTestCase.
We don't need to actually obtain the cache reference in init() to detect whether
needed classes are available. Just a ref to the CacheManager is sufficient. Defer
obtaining the cache reference until start().
This problem doesn't affect any released code; it's an effect of the work on
JBAS-7473.
--
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