tonva / pojo-mbean

Automatically exported from code.google.com/p/pojo-mbean
0 stars 0 forks source link

Register mBean to another MBeanServer than ManagementFactory.getPlatformMBeanServer() #30

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Id like to register my mBeans to a specific mBeanServer
not to the default one ManagementFactory.getPlatformMBeanServer()

This could be done by adding a new constructor MBeanRegistration that takes a 
MBeanServer as a parameter

<code>
/**
  * @param mBean
  *            an MBean instance in the form of a traditional MBean (implementing a sibling *MBean interface) or an
  *            MXBean (implementing an interface annotated with {@code @MXBean}), or an instance implementing the
  *            DynamicMBean interface.
  * @param mBeanObjectName
  *            the object name with which {@code mBean} will be registered
  * @param mBeanServer
  *            the MBeanServer to register the mBean in
  */
public MBeanRegistration(Object mBean, ObjectName mBeanObjectName, MBeanServer 
mBeanServer)
{
   this.mBean = mBean;
   this.mBeanObjectName = mBeanObjectName;
   this.mBeanServer = mBeanServer;
}
</code>

Original issue reported on code.google.com by Martin.B...@gmail.com on 8 Feb 2013 at 10:13

GoogleCodeExporter commented 9 years ago

Original comment by Martin.B...@gmail.com on 17 May 2013 at 11:46

GoogleCodeExporter commented 9 years ago

Original comment by Martin.B...@gmail.com on 17 May 2013 at 11:47

GoogleCodeExporter commented 9 years ago
This issue was closed by revision r150.

Original comment by Martin.B...@gmail.com on 20 May 2013 at 8:10