Externalize the Description of an MBean’s Management Interface
The purpose of a management interface is to define the contract
between an operator and the resources in your application. JMX
defines patterns and an API for defining the management interfaces
for your MBeans. A standard MBean’s management
interface is static because it is defined using a Java interface. As
a result, you are required to code the instrumentation necessary to
support the definition of the management interface according to JMX
MBean design patterns. A dynamic MBean’s management
interface is described programmatically through the use of metadata
classes. The necessary instrumentation to support the definition of
the management interface is a combination of your implementation of
DynamicMBean and the methods in the underlying
MBean resource. Regardless of the type of MBean strategy you choose,
the definition of the management interface is internalized, or
internal to the MBean resource code.
The main issue with instrumenting and defining a resource’s management interface entirely in source code is that only a Java programmer can change it. Should the management interface need to be altered at deployment time, for example, the deployer needs to have Java programming skills, or access to a Java programmer.
This is not a new concern and is one that has been addressed in a number of ways. The Enterprise JavaBeans (EJB) specification provides a mechanism to handle deployment-time modifications to the runtime behavior ...