Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8140572

java.lang.NoClassDefFoundError: com/sun/management/internal/GarbageCollectorExtI

    Details

      Description

      FULL PRODUCT VERSION :
      java version "1.9.0-ea"
      Java(TM) SE Runtime Environment (build 1.9.0-ea-b82)
      Java HotSpot(TM) 64-Bit Server VM (build 1.9.0-ea-b82, mixed mode)


      ADDITIONAL OS VERSION INFORMATION :
      Microsoft Windows [Wersja 6.1.7601]

      A DESCRIPTION OF THE PROBLEM :
      Call to:

      java.lang.management.ManagementFactory.getPlatformMBeanServer();

      Fails with:
      java.lang.NoClassDefFoundError: com/sun/management/internal/GarbageCollectorExtImpl

      Actuall test case that I'm working with is initalization of Apache Common Java Caching System. This fails with trace:
      java.lang.NoClassDefFoundError: com/sun/management/internal/GarbageCollectorExtImpl
              at sun.management.MemoryImpl.getMemoryManagers0(Native Method)
              at sun.management.MemoryImpl.getMemoryManagers(MemoryImpl.java:98)
              at sun.management.ManagementFactoryHelper.getGarbageCollectorMXBeans(ManagementFactoryHelper.java:130)
              at java.lang.management.DefaultPlatformMBeanProvider$4.nameToMBeanMap(DefaultPlatformMBeanProvider.java:185)
              at java.lang.management.ManagementFactory.lambda$getPlatformMBeanServer$0(ManagementFactory.java:478)
              at java.util.stream.ReferencePipeline$7$1.accept(ReferencePipeline.java:269)
              at java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:177)
              at java.util.HashMap$ValueSpliterator.forEachRemaining(HashMap.java:1664)
              at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:482)
              at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:472)
              at java.util.stream.ForEachOps$ForEachOp.evaluateSequential(ForEachOps.java:151)
              at java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateSequential(ForEachOps.java:174)
              at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
              at java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:430)
              at java.lang.management.ManagementFactory.getPlatformMBeanServer(ManagementFactory.java:479)
              at org.apache.commons.jcs.engine.control.CompositeCacheManager.initialize(CompositeCacheManager.java:262)
              at org.apache.commons.jcs.engine.control.CompositeCacheManager.getUnconfiguredInstance(CompositeCacheManager.java:214)
              at org.openstreetmap.josm.data.cache.JCSCacheManager.initialize(JCSCacheManager.java:117)
              at org.openstreetmap.josm.data.cache.JCSCacheManager.getCache(JCSCacheManager.java:148)
              at org.openstreetmap.josm.gui.layer.AbstractCachedTileSourceLayer.getCache(AbstractCachedTileSourceLayer.java:122)
              at org.openstreetmap.josm.gui.layer.AbstractCachedTileSourceLayer.getTileLoaderFactory(AbstractCachedTileSourceLayer.java:113)
              at org.openstreetmap.josm.gui.bbox.SlippyMapBBoxChooser.<init>(SlippyMapBBoxChooser.java:143)
              at org.openstreetmap.josm.gui.download.SlippyMapChooser.<init>(SlippyMapChooser.java:34)
              at org.openstreetmap.josm.gui.download.DownloadDialog.buildMainPanel(DownloadDialog.java:122)
              at org.openstreetmap.josm.gui.download.DownloadDialog.<init>(DownloadDialog.java:234)
              at org.openstreetmap.josm.gui.download.DownloadDialog.<init>(DownloadDialog.java:222)
              at org.openstreetmap.josm.gui.download.DownloadDialog.getInstance(DownloadDialog.java:66)
              at org.openstreetmap.josm.actions.DownloadAction.actionPerformed(DownloadAction.java:43)
              at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2026)
              at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2366)
              at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:404)
              at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:261)
              at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:266)
              at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:297)
              at java.awt.Component.processMouseEvent(Component.java:6607)
              at javax.swing.JComponent.processMouseEvent(JComponent.java:3361)
              at java.awt.Component.processEvent(Component.java:6372)
              at java.awt.Container.processEvent(Container.java:2259)
              at java.awt.Component.dispatchEventImpl(Component.java:4991)
              at java.awt.Container.dispatchEventImpl(Container.java:2317)
              at java.awt.Component.dispatchEvent(Component.java:4823)
              at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4906)
              at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4543)
              at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4484)
              at java.awt.Container.dispatchEventImpl(Container.java:2303)
              at java.awt.Window.dispatchEventImpl(Window.java:2759)
              at java.awt.Component.dispatchEvent(Component.java:4823)
              at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:761)
              at java.awt.EventQueue.access$500(EventQueue.java:97)
              at java.awt.EventQueue$3.run(EventQueue.java:712)
              at java.awt.EventQueue$3.run(EventQueue.java:706)
              at java.security.AccessController.doPrivileged(Native Method)
              at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:77)
              at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:87)
              at java.awt.EventQueue$4.run(EventQueue.java:734)
              at java.awt.EventQueue$4.run(EventQueue.java:732)
              at java.security.AccessController.doPrivileged(Native Method)
              at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:77)
              at java.awt.EventQueue.dispatchEvent(EventQueue.java:731)
              at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:192)
              at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:117)
              at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:106)
              at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:102)
              at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:94)
              at java.awt.EventDispatchThread.run(EventDispatchThread.java:83)



      REGRESSION. Last worked in version 8u60

      ADDITIONAL REGRESSION INFORMATION:
      java version "1.8.0_51"
      Java(TM) SE Runtime Environment (build 1.8.0_51-b16)
      Java HotSpot(TM) 64-Bit Server VM (build 25.51-b03, mixed mode)

      STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
      Call:

      java.lang.management.ManagementFactory.getPlatformMBeanServer();


      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      No exception thrown
      ACTUAL -
      java.lang.NoClassDefFoundError: com/sun/management/internal/GarbageCollectorExtImpl
              at sun.management.MemoryImpl.getMemoryManagers0(Native Method)
              at sun.management.MemoryImpl.getMemoryManagers(MemoryImpl.java:98)
              at sun.management.ManagementFactoryHelper.getGarbageCollectorMXBeans(ManagementFactoryHelper.java:130)
              at java.lang.management.DefaultPlatformMBeanProvider$4.nameToMBeanMap(DefaultPlatformMBeanProvider.java:185)
              at java.lang.management.ManagementFactory.lambda$getPlatformMBeanServer$0(ManagementFactory.java:478)
              at java.util.stream.ReferencePipeline$7$1.accept(ReferencePipeline.java:269)
              at java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:177)
              at java.util.HashMap$ValueSpliterator.forEachRemaining(HashMap.java:1664)
              at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:482)
              at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:472)
              at java.util.stream.ForEachOps$ForEachOp.evaluateSequential(ForEachOps.java:151)
              at java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateSequential(ForEachOps.java:174)
              at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
              at java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:430)
              at java.lang.management.ManagementFactory.getPlatformMBeanServer(ManagementFactory.java:479)
              at org.apache.commons.jcs.engine.control.CompositeCacheManager.initialize(CompositeCacheManager.java:262)
              at org.apache.commons.jcs.engine.control.CompositeCacheManager.getUnconfiguredInstance(CompositeCacheManager.java:214)
              at org.openstreetmap.josm.data.cache.JCSCacheManager.initialize(JCSCacheManager.java:117)
              at org.openstreetmap.josm.data.cache.JCSCacheManager.getCache(JCSCacheManager.java:148)
              at org.openstreetmap.josm.gui.layer.AbstractCachedTileSourceLayer.getCache(AbstractCachedTileSourceLayer.java:122)
              at org.openstreetmap.josm.gui.layer.AbstractCachedTileSourceLayer.getTileLoaderFactory(AbstractCachedTileSourceLayer.java:113)
              at org.openstreetmap.josm.gui.bbox.SlippyMapBBoxChooser.<init>(SlippyMapBBoxChooser.java:143)
              at org.openstreetmap.josm.gui.download.SlippyMapChooser.<init>(SlippyMapChooser.java:34)
              at org.openstreetmap.josm.gui.download.DownloadDialog.buildMainPanel(DownloadDialog.java:122)
              at org.openstreetmap.josm.gui.download.DownloadDialog.<init>(DownloadDialog.java:234)
              at org.openstreetmap.josm.gui.download.DownloadDialog.<init>(DownloadDialog.java:222)
              at org.openstreetmap.josm.gui.download.DownloadDialog.getInstance(DownloadDialog.java:66)
              at org.openstreetmap.josm.actions.DownloadAction.actionPerformed(DownloadAction.java:43)
              at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2026)
              at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2366)
              at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:404)
              at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:261)
              at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:266)
              at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:297)
              at java.awt.Component.processMouseEvent(Component.java:6607)
              at javax.swing.JComponent.processMouseEvent(JComponent.java:3361)
              at java.awt.Component.processEvent(Component.java:6372)
              at java.awt.Container.processEvent(Container.java:2259)
              at java.awt.Component.dispatchEventImpl(Component.java:4991)
              at java.awt.Container.dispatchEventImpl(Container.java:2317)
              at java.awt.Component.dispatchEvent(Component.java:4823)
              at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4906)
              at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4543)
              at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4484)
              at java.awt.Container.dispatchEventImpl(Container.java:2303)
              at java.awt.Window.dispatchEventImpl(Window.java:2759)
              at java.awt.Component.dispatchEvent(Component.java:4823)
              at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:761)
              at java.awt.EventQueue.access$500(EventQueue.java:97)
              at java.awt.EventQueue$3.run(EventQueue.java:712)
              at java.awt.EventQueue$3.run(EventQueue.java:706)
              at java.security.AccessController.doPrivileged(Native Method)
              at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:77)
              at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:87)
              at java.awt.EventQueue$4.run(EventQueue.java:734)
              at java.awt.EventQueue$4.run(EventQueue.java:732)
              at java.security.AccessController.doPrivileged(Native Method)
              at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:77)
              at java.awt.EventQueue.dispatchEvent(EventQueue.java:731)
              at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:192)
              at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:117)
              at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:106)
              at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:102)
              at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:94)
              at java.awt.EventDispatchThread.run(EventDispatchThread.java:83)

      REPRODUCIBILITY :
      This bug can be reproduced always.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              webbuggrp Webbug Group
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: