Uploaded image for project: 'XWiki Commons'
  1. XWiki Commons
  2. XCOMMONS-2188

NPE when interacting with the Infinispan Statistics component via JMX

    XMLWordPrintable

Details

    • Unknown
    • N/A
    • N/A

    Description

      A NullPointerException is thrown when trying to access the numberOfEntries property or any other one of the Statistics component via JMX.

      Steps to reproduce (taken from ADMINTOOL-76):

      {{groovy}}
      import java.lang.management.ManagementFactory;
      import javax.management.MBeanServer;
      import javax.management.ObjectName;
      
      def MBeanServer server = ManagementFactory.getPlatformMBeanServer()
      def query = new ObjectName("org.xwiki.infinispan:component=Statistics,*")
      def names = server.queryNames(query, null)
      names.each {
        def mbean = new GroovyMBean(server, it)
        def name = it.getKeyProperty('name')
        println "* ${name}: size: ${mbean.getProperty("numberOfEntries")}"
      }
      {{/groovy}}
      

      Result: a NPE is thrown

      Attachments

        Issue Links

          Activity

            People

              slauriere slauriere
              slauriere slauriere
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: