Querying the MBeanRegistry should work:

import javax.management.ObjectName;
import org.jboss.mx.server.ServerConstants;
import org.jboss.mx.server.registry.MBeanEntry;
import org.jboss.mx.server.registry.MBeanRegistry;

   Object[] args = {xmbeanName};
   String[] sig = {ObjectName.class.getName()}
   MBeanEntry entry = (MBeanEntry)
        mbeanServer.invoke(ServerConstants.MBEAN_REGISTRY, "get", args, sig);
   Object xmbean = entry.getResourceInstance();

--
xxxxxxxxxxxxxxxxxxxxxxxx
Scott Stark
Chief Technology Officer
JBoss Group, LLC
xxxxxxxxxxxxxxxxxxxxxxxx


Eric Jain wrote:


Is there any way to get a reference from within a managed object to the
surounding XMBean? The managed object is an MBean and may in rare cases
need to modify the MBeanInfo provided by the XMBean on its behalf.

--
Eric Jain



------------------------------------------------------- This SF.Net email sponsored by: Parasoft Error proof Web apps, automate testing & more. Download & eval WebKing and get a free book. www.parasoft.com/bulletproofapps _______________________________________________ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to