-
1. Re: org.jboss.mx.server.MBeanServerBuilderImpl cannot be cast to javax .management.MBeanServerBuilder
rnappert Nov 25, 2011 4:22 PM (in response to rnappert)If I uses find the MBeanServer with
mbserver = java.lang.management.ManagementFactory.getPlatformMBeanServer(),
it still works with JBoss 4.2, but still fails on JBoss AS 6. Now, I get the following:
Servlet threw load() exception: javax.servlet.ServletException: Could not instantiate Locator [java.lang.LinkageError: loader constraint violation: when resolving method "java.lang.management.ManagementFactory.getPlatformMBeanServer()Ljavax/management/MBeanServer;" the class loader (inst
ance of org/jboss/classloader/spi/base/BaseClassLoader) of the current class, /mbeans/Mgmt, and the class loader (instance of <bootloader>) for resolved class, java/lang/management/ManagementFactory, have different Class objects for the type javax/management/MBeanServer used in the signature]
Any feedback is highly appreciated.
-
2. Re: org.jboss.mx.server.MBeanServerBuilderImpl cannot be cast to javax .management.MBeanServerBuilder
rnappert Nov 25, 2011 4:36 PM (in response to rnappert)Found a solution! I had a jmx lib in WEB-INF/lib, which also contained the javax.management.MBeanServer interface. After removing the lib, it seems to deploy and it finds the MBeanServer