[JBoss JIRA] Created: (JBCACHE-1487) Node count fails when Cache.toString() called between @Inject and @Start methods.
by Galder Zamarreno (JIRA)
Node count fails when Cache.toString() called between @Inject and @Start methods.
---------------------------------------------------------------------------------
Key: JBCACHE-1487
URL: https://jira.jboss.org/jira/browse/JBCACHE-1487
Project: JBoss Cache
Issue Type: Bug
Security Level: Public (Everyone can see)
Affects Versions: 3.0.3.GA
Reporter: Galder Zamarreno
Assignee: Manik Surtani
Node count fails when Cache bean is deployed via MC and TRACE is enabled on org.jboss.kernel:
2009-03-03 21:40:51,505 ERROR [AbstractKernelController] (main) Error installing to Instantiated: name=CacheClusterA1 state=Described
java.lang.UnsupportedOperationException: Not supported in UnversionedNode
at org.jboss.cache.AbstractNode.getChildrenDirect(AbstractNode.java:277)
at org.jboss.cache.mvcc.NodeReference.getChildrenDirect(NodeReference.java:272)
at org.jboss.cache.invocation.NodeInvocationDelegate.getChildrenDirect(NodeInvocationDelegate.java:163)
at org.jboss.cache.DataContainerImpl.numNodes(DataContainerImpl.java:461)
at org.jboss.cache.DataContainerImpl.getNumberOfNodes(DataContainerImpl.java:438)
at org.jboss.cache.DataContainerImpl.toString(DataContainerImpl.java:394)
at org.jboss.cache.DataContainerImpl.toString(DataContainerImpl.java:372)
at org.jboss.cache.invocation.CacheInvocationDelegate.toString(CacheInvocationDelegate.java:144)
at java.lang.String.valueOf(String.java:2615)
at org.jboss.util.JBossStringBuilder.append(JBossStringBuilder.java:114)
at org.jboss.dependency.plugins.AbstractControllerContext.toString(AbstractControllerContext.java:362)
MC is printing the cache content in between the two calls to DataContainerImpl.createRootNode(). First
call happens during the @Inject phase and at that point, DataContainerImpl's config has not been set yet
so, getting node numbers is called with usingMvcc=false. This leads to getChildrenDirect() being called
on the root node and this call fails.
See attached logs to compare deployment when TRACE is enabled versus deployment when DEBUG is enabled.
--
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