Wednesday, 19 January 2011

JMX and the Java Console

Working through an Apache Service Mix tutorial I have discovered JMX ( Java Management Extension). JMX provided since Java 5 is mechanism for managing and monitoring applications, system objects, devices (e. g. printers ) and service oriented networks .



Resources are represented by objects called MBeans (Managed Beans). The MBean represents resource running in the JVM, such as an application or a Java EE technical service (transactional monitor, JDBC driver, etc.). They can be used for getting and setting applications configuration (pull), for collecting statistics (pull) (e.g. performance, resources usage, problems) and notifying events (push) (e.g. faults, state changes).



Service Mix allows all aspects of the ESB (components, endpoints, ...) to monitored and managed using JMX.

The Java Console (/usr/lib/jvm/java-6-sun-1.6.0.22/bin/jconsole) enables the state of all objects running inside the JVM to be interrogated and even allows methods for objects inside the heap to be called. The connection is selected when running the console.




No comments: