Java Jmx


The simplest way to understand the way that JMX works is to divide its functionality into 3 layers: the Instrumentation Level, the Agent Level, and the Remote Management Level.

The Instrumentation Level contains the components and resources that you would like to manage. These resources are represented by one or more specialized JavaBeans known as Managed Beans, or MBeans. MBeans are Java Beans that implement additional components which allow them to be managed and monitored via the JMX framework. Each MBean represents a single resource running on the JVM, which is exposed for remote management using JMX.

There are different type of MBeans, each with different functionalities, which offer a greater degree of flexibility when designing your administrative framework. Any MBean that you wish to expose is registered with the MBeanServer, which makes up JMX's Agent Level.

The Agent Level is composed of an intermediate agent called MBeanServer. The job of this layer is to receive requests or commands from the Remote Management Level, and relay them to the appropriate MBean. It also can receive notifications from its MBeans, such as state changes and forward them to the Remote Management Level.

The Remote Management Level is made up of client programs, connectors, and adaptors and allows the user to send requests to the Agent Layer for relay and receive the results of these request. Users can connect to the MBeanServer either through a connector, using a client program such as JConsole and a protocol such as RMI or IIOP, or through an adaptor, which adapts the MBeanServer API to another protocol, such as HTTP, allowing JMX to be used with custom web-based GUIs.

In summary, a user at the Remote Management Level sends a request or command to the Agent Level, which contacts the appropriate MBean at the Instrumentation Level, and relays the response back to the user.

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License