org.apache.camel.spi
Interface InstrumentationAgent

All Superinterfaces:
Service
All Known Implementing Classes:
DefaultInstrumentationAgent

public interface InstrumentationAgent
extends Service

Camel JMX service agent


Method Summary
 String getMBeanObjectDomainName()
          Get domain name for Camel MBeans.
 MBeanServer getMBeanServer()
          Get the MBeanServer which hosts managed objects.
 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 unregister(ObjectName name)
          Unregisters object based upon registered name
 
Methods inherited from interface org.apache.camel.Service
start, stop
 

Method Detail

register

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

Parameters:
obj - the object to register
name - the name
Throws:
JMException - is thrown if the registration failed

register

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

Parameters:
obj - the object to register
name - the name
forceRegistration - if set to true, then object will be registered despite existing object is already registered with the name.
Throws:
JMException - is thrown if the registration failed

unregister

void unregister(ObjectName name)
                throws JMException
Unregisters object based upon registered name

Parameters:
name - the name
Throws:
JMException - is thrown if the unregistration failed

getMBeanServer

MBeanServer getMBeanServer()
Get the MBeanServer which hosts managed objects.

Notice: If the JMXEnabled configuration is not set to true, this method will return null.

Returns:
the MBeanServer

getMBeanObjectDomainName

String getMBeanObjectDomainName()
Get domain name for Camel MBeans.

Notice: That this can be different that the default domain name of the MBean Server.

Returns:
domain name


Apache CAMEL