[
https://issues.jboss.org/browse/ISPN-2756?page=com.atlassian.jira.plugin....
]
Adrian Nistor updated ISPN-2756:
--------------------------------
Status: Resolved (was: Pull Request Sent)
Resolution: Done
Integrated. Thanks!
Enabling/disabling RpcManager statistics via JMX doesn't work
-------------------------------------------------------------
Key: ISPN-2756
URL:
https://issues.jboss.org/browse/ISPN-2756
Project: Infinispan
Issue Type: Bug
Components: JMX, reporting and management
Affects Versions: 5.2.0.CR2
Reporter: Dan Berindei
Assignee: Dan Berindei
Fix For: 5.2.0.Final
The test RpcManagerMBeanTest.testEnableJmxStats tries to write to the
"StatisticsEnabled" attribute but fails. The operation doesn't throw an
exception, but it does log this WARN message:
{noformat}
10:43:42,079 WARN (testng-RpcManagerMBeanTest:) [ResourceDMBean] ISPN000043: Exception
while writing value for attribute statisticsEnabled
java.lang.NullPointerException
at
org.infinispan.jmx.ResourceDMBean$InvokableSetterBasedMBeanAttributeInfo.invoke(ResourceDMBean.java:391)
at org.infinispan.jmx.ResourceDMBean.setNamedAttribute(ResourceDMBean.java:325)
at org.infinispan.jmx.ResourceDMBean.setAttribute(ResourceDMBean.java:212)
at
com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.setAttribute(DefaultMBeanServerInterceptor.java:746)
at com.sun.jmx.mbeanserver.JmxMBeanServer.setAttribute(JmxMBeanServer.java:729)
at
org.infinispan.jmx.RpcManagerMBeanTest.testEnableJmxStats(RpcManagerMBeanTest.java:134)
{noformat}
Because statistics are still enabled, the test then fails with an assertion error:
{noformat}
10:43:42,464 ERROR (testng-RpcManagerMBeanTest:) [UnitTestTestNGListener] Test
testEnableJmxStats(org.infinispan.jmx.RpcManagerMBeanTest) failed.
java.lang.AssertionError: expected [-1] but found [1]
at org.testng.Assert.fail(Assert.java:94)
at org.testng.Assert.failNotEquals(Assert.java:494)
at org.testng.Assert.assertEquals(Assert.java:123)
at org.testng.Assert.assertEquals(Assert.java:165)
at
org.infinispan.jmx.RpcManagerMBeanTest.testEnableJmxStats(RpcManagerMBeanTest.java:138)
{noformat}
--
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