users@glassfish.java.net

Re: Enable glassfish JVM for JMX monitoring, how i can do it?

From: <glassfish_at_javadesktop.org>
Date: Thu, 23 Aug 2007 15:35:12 PDT

I concur on the above, and to clarify:

Setting the various -D flags causes the platform MBeanServer to load prior prior to main() being called in GlassFish. This causes a failure, because the full GlassFish classloader structure is not prepared at that time.

As GlassFish does start the MBeanServer and a remote connector (see Kedar's link), you should simply connect using the "approved" method.
[Message sent by forum member 'llc' (llc)]

http://forums.java.net/jive/thread.jspa?messageID=232402