| java.lang.Object org.jboss.mx.util.MBeanInstaller
MBeanInstaller | public class MBeanInstaller (Code) | | MBean installer utility
This installer allows MLet to install or upgrade a mbean based on the version
specified in the MLet conf file. If the mbean version is newer than the
registered in the server, the installer unregisters the old mbean and then
registers the new one. This management needs to store the mbean version into
the MBeanRegistry in the server.
When we register mbeans, however, we can't pass the metadata to MBeanServer
through the standard JMX api because Both of createMBean() and registerMBean()
have no extra arguments to attach the metadata. Thus we call
MBeanServer.invoke() directly to set/get the internal MBean metadata.
Currently version and date are stored in the mbean registry as mbean metadata.
The date will be used for preparing presentaionString for this mbean info.
For managment purpose, we can add any extra data to the matadata if you need.
author: Fusayuki Minamoto. author: Juha Lindfors. version: $Revision: 57200 $ version: Revisions: version: 20020219 Juha Lindfors: version: |
Constructor Summary | |
public | MBeanInstaller(MBeanServer server, ClassLoader ctxClassLoader, ObjectName loaderName) Create a new MBean installer instance.
Parameters: server - reference to the MBean server where the new MBeans willbe registered to Parameters: ctxClassLoader - Context class loader reference which will be stored in the registry for the new MBeans. |
MBeanInstaller | public MBeanInstaller(MBeanServer server, ClassLoader ctxClassLoader, ObjectName loaderName) throws Exception(Code) | | Create a new MBean installer instance.
Parameters: server - reference to the MBean server where the new MBeans willbe registered to Parameters: ctxClassLoader - Context class loader reference which will be stored in the registry for the new MBeans. Thisclassloader will be set as the thread contextclassloader when the MBean is invoked. Parameters: loaderName - Object name of the classloader that should beused to instantiate the newly registered MBeans.This should normally be the object name of theMLet MBean that is installing the new MBeans. |
|
|