Hi Vishal,

I see the problems and think I can fix it.

At my test env (Linux, Mac OS x) the Registry and Platform MBeanServer are the same. I can see all Tomcat Mbeans at my jconsole.

Many thanks,
Peter


Am 16.02.2008 um 23:18 schrieb Vishal Goenka:

2. JMXAdaptorLifecycleListener registers the PlatformMBean server with the registry whereas Tomcat's MBeans are registered with another MBean server
created using the apache common's modeler registry wrapper code. Hence
Tomcat's MBeans don't show up in JConsole when you connect using the URL that the JMXAdaptorLifecycleListener registers. I'm not entirely sure of a
clean way of doing this. A hack that seems to work is setting the
PlatformMBeanServer as the MBean server to use for Tomcat programmatically. In the constructor of JMXAdaptorLifecycleListener, adding the following does the trick, but only if it is the first listener in the server.xml file:

        org.apache.commons.modeler.Registry.getRegistry(null,
null).setMBeanServer(ManagementFactory.getPlatformMBeanServer());



Reply via email to