Apache CXF API

org.apache.cxf.management.jmx
Class InstrumentationManagerImpl

java.lang.Object
  extended by org.apache.cxf.management.JMXConnectorPolicyType
      extended by org.apache.cxf.management.jmx.InstrumentationManagerImpl
All Implemented Interfaces:
BusLifeCycleListener, InstrumentationManager

public class InstrumentationManagerImpl
extends JMXConnectorPolicyType
implements InstrumentationManager, BusLifeCycleListener

The manager class for the JMXManagedComponent which hosts the JMXManagedComponents.


Field Summary
 
Fields inherited from class org.apache.cxf.management.JMXConnectorPolicyType
daemon, enabled, jmxServiceURL, threaded
 
Constructor Summary
InstrumentationManagerImpl()
           
 
Method Summary
 Bus getBus()
           
 MBeanServer getMBeanServer()
          Get the MBeanServer which hosts managed components NOTE: if the configuration is not set the JMXEnabled to be true, this method will return null
 String getPersistentBusId()
           
 void init()
           
 void initComplete()
          Invoked when the Bus has been initialized.
 void postShutdown()
          Invoked after the Bus is shutdown.
 void preShutdown()
          Invoked before the Bus is shutdown.
 void register()
           
 ObjectName register(ManagedComponent i)
          Register a component with management infrastructure.
 ObjectName register(ManagedComponent i, boolean forceRegistration)
          Register a component with management infrastructure.
 void register(Object obj, ObjectName name)
          Registers object with management infrastructure with a specific name.
 void register(Object obj, ObjectName name, boolean forceRegistration)
          Registers object with management infrastructure with a specific name.
 void setBus(Bus bus)
           
 void setCreateMBServerConnectorFactory(boolean createMBServerConnectorFactory)
           
 void setPersistentBusId(String id)
           
 void setServer(MBeanServer server)
           
 void setServerName(String s)
           
 void setUsePlatformMBeanServer(Boolean flag)
           
 void shutdown()
          Cleans up and shutsdown management infrastructure.
 void unregister(ManagedComponent component)
          Unregisters component with management infrastructure
 void unregister(ObjectName name)
          Unregisters component based upon registered name
 
Methods inherited from class org.apache.cxf.management.JMXConnectorPolicyType
getJMXServiceURL, isDaemon, isEnabled, isThreaded, setDaemon, setEnabled, setJMXServiceURL, setThreaded
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

InstrumentationManagerImpl

public InstrumentationManagerImpl()
Method Detail

getBus

public Bus getBus()

setBus

public void setBus(Bus bus)

setServerName

public void setServerName(String s)

setCreateMBServerConnectorFactory

public void setCreateMBServerConnectorFactory(boolean createMBServerConnectorFactory)

setUsePlatformMBeanServer

public void setUsePlatformMBeanServer(Boolean flag)

register

@PostConstruct
public void register()

init

@PostConstruct
public void init()

register

public void register(Object obj,
                     ObjectName name)
              throws JMException
Description copied from interface: InstrumentationManager
Registers object with management infrastructure with a specific name. Object must be annotated or implement standard MBean interface.

Specified by:
register in interface InstrumentationManager
Throws:
JMException

register

public void register(Object obj,
                     ObjectName name,
                     boolean forceRegistration)
              throws JMException
Description copied from interface: InstrumentationManager
Registers object with management infrastructure with a specific name. Object must be annotated or implement standard MBean interface.

Specified by:
register in interface InstrumentationManager
forceRegistration - if set to true, then component will be registered despite existing component.
Throws:
JMException

register

public ObjectName register(ManagedComponent i)
                    throws JMException
Description copied from interface: InstrumentationManager
Register a component with management infrastructure. Component will supply registration name.

Specified by:
register in interface InstrumentationManager
Returns:
name used to register the component
Throws:
JMException

register

public ObjectName register(ManagedComponent i,
                           boolean forceRegistration)
                    throws JMException
Description copied from interface: InstrumentationManager
Register a component with management infrastructure. Component will supply registration name.

Specified by:
register in interface InstrumentationManager
forceRegistration - if set to true, then component will be registered despite existing component.
Returns:
name used to register the component
Throws:
JMException

unregister

public void unregister(ManagedComponent component)
                throws JMException
Description copied from interface: InstrumentationManager
Unregisters component with management infrastructure

Specified by:
unregister in interface InstrumentationManager
Throws:
JMException

unregister

public void unregister(ObjectName name)
                throws JMException
Description copied from interface: InstrumentationManager
Unregisters component based upon registered name

Specified by:
unregister in interface InstrumentationManager
Throws:
JMException

getMBeanServer

public MBeanServer getMBeanServer()
Description copied from interface: InstrumentationManager
Get the MBeanServer which hosts managed components NOTE: if the configuration is not set the JMXEnabled to be true, this method will return null

Specified by:
getMBeanServer in interface InstrumentationManager
Returns:
the MBeanServer

setServer

public void setServer(MBeanServer server)

shutdown

public void shutdown()
Description copied from interface: InstrumentationManager
Cleans up and shutsdown management infrastructure.

Specified by:
shutdown in interface InstrumentationManager

initComplete

public void initComplete()
Description copied from interface: BusLifeCycleListener
Invoked when the Bus has been initialized.

Specified by:
initComplete in interface BusLifeCycleListener

preShutdown

public void preShutdown()
Description copied from interface: BusLifeCycleListener
Invoked before the Bus is shutdown.

Specified by:
preShutdown in interface BusLifeCycleListener

postShutdown

public void postShutdown()
Description copied from interface: BusLifeCycleListener
Invoked after the Bus is shutdown.

Specified by:
postShutdown in interface BusLifeCycleListener

getPersistentBusId

public String getPersistentBusId()
Specified by:
getPersistentBusId in interface InstrumentationManager

setPersistentBusId

public void setPersistentBusId(String id)
Specified by:
setPersistentBusId in interface InstrumentationManager

Apache CXF API

Apache CXF