A managed bean (MBean) is a Java object that represents a JMX manageable resource in a distributed environment, such as:
- an application,
- a service,
- a component
- or a device.
An MBean is a named managed object representing a resource.
Developers of applications and devices are free to choose the granularity of objects that are instrumented as MBeans. An MBean might represent:
- the smallest object in an application,
- or the entire application.
Application components designed with their management interface in mind can typically be written as MBeans. MBeans can also be used as wrappers for legacy code without a management interface or as proxies for code with a legacy management interface.
The JMX specification defines five types of MBean:
- Dynamic MBeans
- Open MBeans
- Model MBeans
A management application uses the object name to identify the object on which it is to perform a management operation.
The management interface of an MBean consists of:
- A set of readable or writable attributes, or both.
- A set of invokable operations.
- A self-description.
- Typed notifications that can be emitted by the MBean
The Java class of a standard MBean exposes the resource to be managed directly through: