Java Reference
In-Depth Information
hierarchy of the JMX runtime exceptions for the MBean level. Note that JMX
wraps both runtime errors and runtime exceptions in its own runtime exception.
Like JMX exceptions, JMX runtime exceptions at the MBean level are broken
down into three categories:
RuntimeOperationsException —Wraps Java runtime exceptions that occur
during operations on an MBean
RuntimeErrorException —Wraps standard runtime errors of the Java lan-
guage that occur at the MBean level
RuntimeMBeanException —Wraps any other (user-defined or standard) run-
time exceptions thrown from an MBean
4.6 Summary
This chapter introduced the Standard MBean. The Standard MBean uses an
explicitly declared management interface to interact with a manageable
resource. The explicitly declared interface—the MBean interface—makes the
Standard MBean a static, unchanging MBean used for well-known or pre-
defined resources.
The examples in this chapter covered the three following topics:
Configuration— Using MBeans to make your applications more configurable.
The example was a Standard MBean used to manage a properties object.
Componentization— Using MBeans to break your applications into compo-
nents, allowing you to alter or replace component implementations. The
Logger MBean demonstrated this concept.
MBeans using MBeans— Combining both previous concepts, the Logger MBean
used the PropertyManager MBean to initialize one of its member variables.
At the end of this chapter, you got your first look at the exception hierarchy for
exceptions that occur when working with MBeans. JMX provides exceptions for
many situations that may occur when reflecting upon or invoking MBean
objects. In addition, JMX provides other exception classes to wrap core Java
exceptions and user-defined exceptions.
Chapter 5 introduces the Dynamic MBean. The Dynamic MBean is used to
manage evolving resources in situations where the Standard MBean may not
be appropriate.
Search WWH ::




Custom Search