[
https://issues.jboss.org/browse/AS7-6949?page=com.atlassian.jira.plugin.s...
]
Brian Stansberry updated AS7-6949:
----------------------------------
Description:
Intermittent testsuite failures, e.g.
http://lightning.mw.lab.eng.bos.redhat.com/jenkins/job/as7-param-pull/684...
Log shows this repeatedly:
[4/18/13 7:17:27 PM] Brian Stansberry: [0m[33m18:38:11,612 WARN
[org.jboss.remotingjmx.protocol.v2.ServerCommon] (pool-2-thread-12) Unexpected internal
error: java.lang.NullPointerException
at
org.jboss.as.jmx.model.RootResourceIterator.doIterate(RootResourceIterator.java:49)
at
org.jboss.as.jmx.model.RootResourceIterator.doIterate(RootResourceIterator.java:55)
at
org.jboss.as.jmx.model.RootResourceIterator.doIterate(RootResourceIterator.java:55)
at org.jboss.as.jmx.model.RootResourceIterator.iterate(RootResourceIterator.java:39)
at
org.jboss.as.jmx.model.ModelControllerMBeanHelper.getMBeanCount(ModelControllerMBeanHelper.java:103)
at
org.jboss.as.jmx.model.ModelControllerMBeanServerPlugin.getMBeanCount(ModelControllerMBeanServerPlugin.java:116)
at
org.jboss.as.jmx.PluggableMBeanServerImpl.getMBeanCount(PluggableMBeanServerImpl.java:220)
at
org.jboss.remotingjmx.protocol.v2.ServerProxy$GetMBeanCountHandler.handle(ServerProxy.java:618)
at
org.jboss.remotingjmx.protocol.v2.ServerCommon$MessageReciever$1.run(ServerCommon.java:152)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
[rt.jar:1.7.0_13]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
[rt.jar:1.7.0_13]
at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0_13]
RootResourceIterator.doIterate is reading the resource twice:
{code}
for (ResourceEntry entry : current.getChildren(type)) {
final PathElement pathElement = entry.getPathElement();
final Resource child = current.getChild(pathElement); // why this
call since "entry" and "child" should be the same object
final PathAddress childAddress = address.append(pathElement);
doIterate(child, childAddress);
}
{code}
The problem is "child" is null, which is possible with a dynamic resource. So,
either "entry" should be used, or, if there is some reason for the 2nd read, a
check for null is needed before the recursive doIterate call.
Environment: (was: Intermittent testsuite failures, e.g.
http://lightning.mw.lab.eng.bos.redhat.com/jenkins/job/as7-param-pull/684...
Log shows this repeatedly:
[4/18/13 7:17:27 PM] Brian Stansberry: [0m[33m18:38:11,612 WARN
[org.jboss.remotingjmx.protocol.v2.ServerCommon] (pool-2-thread-12) Unexpected internal
error: java.lang.NullPointerException
at
org.jboss.as.jmx.model.RootResourceIterator.doIterate(RootResourceIterator.java:49)
at
org.jboss.as.jmx.model.RootResourceIterator.doIterate(RootResourceIterator.java:55)
at
org.jboss.as.jmx.model.RootResourceIterator.doIterate(RootResourceIterator.java:55)
at org.jboss.as.jmx.model.RootResourceIterator.iterate(RootResourceIterator.java:39)
at
org.jboss.as.jmx.model.ModelControllerMBeanHelper.getMBeanCount(ModelControllerMBeanHelper.java:103)
at
org.jboss.as.jmx.model.ModelControllerMBeanServerPlugin.getMBeanCount(ModelControllerMBeanServerPlugin.java:116)
at
org.jboss.as.jmx.PluggableMBeanServerImpl.getMBeanCount(PluggableMBeanServerImpl.java:220)
at
org.jboss.remotingjmx.protocol.v2.ServerProxy$GetMBeanCountHandler.handle(ServerProxy.java:618)
at
org.jboss.remotingjmx.protocol.v2.ServerCommon$MessageReciever$1.run(ServerCommon.java:152)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
[rt.jar:1.7.0_13]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
[rt.jar:1.7.0_13]
at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0_13]
RootResourceIterator.doIterate is reading the resource twice:
{code}
for (ResourceEntry entry : current.getChildren(type)) {
final PathElement pathElement = entry.getPathElement();
final Resource child = current.getChild(pathElement); // why this
call since "entry" and "child" should be the same object
final PathAddress childAddress = address.append(pathElement);
doIterate(child, childAddress);
}
{code}
The problem is "child" is null, which is possible with a dynamic resource. So,
either "entry" should be used, or, if there is some reason for the 2nd read, a
check for null is needed before the recursive doIterate call.)
NPE in RootResourceIterator
---------------------------
Key: AS7-6949
URL:
https://issues.jboss.org/browse/AS7-6949
Project: Application Server 7
Issue Type: Bug
Components: Domain Management, JMX
Reporter: Brian Stansberry
Assignee: Brian Stansberry
Fix For: 8.0.0.Alpha1
Intermittent testsuite failures, e.g.
http://lightning.mw.lab.eng.bos.redhat.com/jenkins/job/as7-param-pull/684...
Log shows this repeatedly:
[4/18/13 7:17:27 PM] Brian Stansberry: [0m[33m18:38:11,612 WARN
[org.jboss.remotingjmx.protocol.v2.ServerCommon] (pool-2-thread-12) Unexpected internal
error: java.lang.NullPointerException
at
org.jboss.as.jmx.model.RootResourceIterator.doIterate(RootResourceIterator.java:49)
at
org.jboss.as.jmx.model.RootResourceIterator.doIterate(RootResourceIterator.java:55)
at
org.jboss.as.jmx.model.RootResourceIterator.doIterate(RootResourceIterator.java:55)
at org.jboss.as.jmx.model.RootResourceIterator.iterate(RootResourceIterator.java:39)
at
org.jboss.as.jmx.model.ModelControllerMBeanHelper.getMBeanCount(ModelControllerMBeanHelper.java:103)
at
org.jboss.as.jmx.model.ModelControllerMBeanServerPlugin.getMBeanCount(ModelControllerMBeanServerPlugin.java:116)
at
org.jboss.as.jmx.PluggableMBeanServerImpl.getMBeanCount(PluggableMBeanServerImpl.java:220)
at
org.jboss.remotingjmx.protocol.v2.ServerProxy$GetMBeanCountHandler.handle(ServerProxy.java:618)
at
org.jboss.remotingjmx.protocol.v2.ServerCommon$MessageReciever$1.run(ServerCommon.java:152)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
[rt.jar:1.7.0_13]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
[rt.jar:1.7.0_13]
at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0_13]
RootResourceIterator.doIterate is reading the resource twice:
{code}
for (ResourceEntry entry : current.getChildren(type)) {
final PathElement pathElement = entry.getPathElement();
final Resource child = current.getChild(pathElement); // why
this call since "entry" and "child" should be the same object
final PathAddress childAddress = address.append(pathElement);
doIterate(child, childAddress);
}
{code}
The problem is "child" is null, which is possible with a dynamic resource. So,
either "entry" should be used, or, if there is some reason for the 2nd read, a
check for null is needed before the recursive doIterate call.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:
http://www.atlassian.com/software/jira