Uploaded image for project: 'Qpid'
  1. Qpid
  2. QPID-8355

[Broker-J] BrokerAttributeInjector can't load HotSpotDiagnosticMXBean on Eclipse J9

    XMLWordPrintableJSON

    Details

      Description

      Switching JVM to Eclipse J9 triggered this problem:

       

      java.util.ServiceConfigurationError: org.apache.qpid.server.plugin.ConfiguredObjectAttributeInjector: Provider org.apache.qpid.server.model.BrokerAttributeInjector could not be instantiated
          at java.util.ServiceLoader.fail(ServiceLoader.java:232)
          at java.util.ServiceLoader.access$100(ServiceLoader.java:185)
          at java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:384)
          at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:404)
          at java.util.ServiceLoader$1.next(ServiceLoader.java:480)
          at org.apache.qpid.server.plugin.QpidServiceLoader.instancesOf(QpidServiceLoader.java:73)
          at org.apache.qpid.server.plugin.QpidServiceLoader.instancesOf(QpidServiceLoader.java:43)
          at org.apache.qpid.server.model.SystemConfigBootstrapModel.<init>(SystemConfigBootstrapModel.java:49)
          at org.apache.qpid.server.model.SystemConfigBootstrapModel.<clinit>(SystemConfigBootstrapModel.java:36)
          at org.apache.qpid.server.model.AbstractSystemConfig.<init>(AbstractSystemConfig.java:128)
          at org.apache.qpid.server.store.MemorySystemConfigImpl.<init>(MemorySystemConfigImpl.java:46)
          at org.apache.qpid.server.store.MemorySystemConfigImplFactory.newInstance(MemorySystemConfigImplFactory.java:51)
          at org.apache.qpid.server.store.MemorySystemConfigImplFactory.newInstance(MemorySystemConfigImplFactory.java:32)
          at org.apache.qpid.server.SystemLauncher.startupImpl(SystemLauncher.java:258)
          at org.apache.qpid.server.SystemLauncher.access$200(SystemLauncher.java:65)
          at org.apache.qpid.server.SystemLauncher$1.run(SystemLauncher.java:217)
          at java.security.AccessController.doPrivileged(AccessController.java:770)
          at javax.security.auth.Subject.doAs(Subject.java:422)
          at org.apache.qpid.server.SystemLauncher.startup(SystemLauncher.java:208)
      Caused by: java.lang.IllegalArgumentException: com.sun.management.HotSpotDiagnosticMXBean is not a valid MXBean interface.
          at com.ibm.java.lang.management.internal.ManagementUtils.checkSupported(ManagementUtils.java:647)
          at com.ibm.java.lang.management.internal.ManagementUtils.checkSupportedSingleton(ManagementUtils.java:652)
          at com.ibm.java.lang.management.internal.ManagementUtils.getPlatformMXBean(ManagementUtils.java:675)
          at java.lang.management.ManagementFactory.getPlatformMXBean(ManagementFactory.java:331)
          at org.apache.qpid.server.model.BrokerAttributeInjector.<init>(BrokerAttributeInjector.java:71)
          at java.lang.J9VMInternals.newInstanceImpl(Native Method)
          at java.lang.Class.newInstance(Class.java:1848)
          at java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:380)

       

      I see it was almost fixed in QPID-7081, but, AFAIS, ManagementFactory.getPlatformMXBean can throw an IllegalArgumentException if the bean is not present.

        Attachments

          Activity

            People

            • Assignee:
              orudyy Alex Rudyy
              Reporter:
              shadow Andrei Ivanov
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: