Java Reference
In-Depth Information
2.5.2
MBean View
MBean View is another HTML page received from the HTML adapter that shows
information about the MBean you clicked. MBean View presents you with all the
details of the selected MBean, including the information shown in table 2.3.
Table 2.3
The elements of MBean View
MBean detail
Description or example
Class name
Main class of the MBean, such as HelloWorld .
Object name
Object name of the MBean, such as HelloAgent:name=helloWorld1 .
Description
Description of the MBean. For Standard MBeans, the MBeanServer creates the
description.
Attributes table
Lists the exposed attributes of the selected MBean, including the type, access, and
value if possible. The attributes table also allows you to change writable attributes.
Exposed operations
List of operations exposed by the MBean. From here you can invoke an operation.
Reload Period
Tells the MBeanServer if it needs to reinstantiate this MBean, and if so, how often.
Unregister button
Tells the MBeanServer to unregister this MBean.
Figure 2.6 depicts the MBean view of the MBeanServerDelegate MBean.
Look at the table of MBean attributes in figure 2.6, and notice the values in the
Access column. Currently, all rows contain the value RO, which stands for Read
Only. Other possible values are WO (Write Only) and RW (Read/Write) access. As
you might suspect, RO implies that the MBean's Java interface has provided only
a getter method for an attribute. WO access implies that there is only a setter
method, and RW implies that both a setter and a getter exist for this attribute.
The HTML adapter is using the reflection API to examine the method names
from the interface. It removes the get or set of each method name and creates
the attribute name from the remaining method name portion. Remaining
methods (those without get or set at the start of their names) go into the Oper-
ations section of the MBean View.
By looking back at figure 2.6, you see that the MBeanServerDelegate exposes
only read-only attributes. These attributes describe the reference implementa-
tion being used and which version of the JMX specification it implements.
Let's go back to the Agent View by clicking the Back to Agent View link. This
time, select your HelloWorld MBean. Figure 2.7 shows what you should see.
The view of the HelloWorld MBean is displayed exactly like that of the MBean-
ServerDelegate MBean, except for two important differences. Remember that
Search WWH ::




Custom Search