Sunday, May 4, 2014

JMX Getting Started: Standard MBean

Simple Note


From official site:
The JMX technology provides the tools for building distributed, Web-based, modular and dynamic solutions for managing and monitoring devices, applications, and service-driven networks. By design, this standard is suitable for adapting legacy systems, implementing new management and monitoring solutions, and plugging into those of the future. 

This article describe how to write JMX Standard MBeans.


View demo on line

The testing class to run.
Test java bean, contains some operations and attribute.
The interface for TestBean, according to JMX Standard MBean convention the name should be TestBeanMBean.

How to Run (Windows7/JDK6)

1. Download the bin/test  folder to some where.

2. Open cmd, go to the folder that contains the downloaded test folder.

3. Run it with "java -cp . test.Test".

4. Open jconsole.exe at your jdk/bin folder and try it.

1. If you didn't setup PATH properly (i.e. cannot execute java command any where) you can copy test folder to path_to_your_jdk_folder/bin.

2. You may need to change TMP folder to different location, please refer to the related thread on oracle community.


Standard MBean

TMP Issue


Full project at github

1 comment:

  1. The information you've shared in this blog is remarkable. Thanks for sharing such quality information.

    On Demand Service Apps For Android and iOS are highly in demand as through this online platform. App ideas provide them on-demand service when customers need it.