Broker Monitoring Tool Sample Application

What it is

This is a simple monitoring example which demonstrates how to retrieve information about the state of a broker cluster(s).

It is just an example to help you write your own monitoring tools; it is not intended to be used for any other purpose and is not supported.

Most of the broker data displayed by this example is obtained using the MQ JMS API. For more information, see the Developer's Guide for JMX Clients in the MQ documentation set.

Data about individual messages is obtained using the unsupported msgadmin API classes. A copy of these classes can be found in the examples.mm.model.jms package.

For more information on the msgadmin API classes, see the FAQ for unsupported features in Open Message Queue on the Open Message Queue wiki.

How to run it

Source code and classes can be found in MQMonitor.zip.

The example requires the following jars:

  • imq.jar
  • imqjmx.jar
  • jms.jar
  • imqadmin.jar
  • imqutil.jar

To run type:

java -cp <class path to mq jars and the example class files> examples.mm.MQMonitor

How to use it

When you run the tool an empty window opens. Press "Connect to cluster". Enter the details of a broker in the cluster and press OK.


The window is then populated with details of the specified broker and all the others in the same cluster.

Each broker is shown in a separate tab. The first tab is entitled "All Brokers" and collates the information for all the brokers in the cluster. Subsequent tabs are used to display information for individual brokers.


In the destinations table, select a destination and then press "display message". A new window opens which lists the messages in that destination.

Note that the "display message" button will be disabled if you are viewing the "All Brokers" tab. You need to select a specific broker to view its messages.


Select an individual message and then press "Show Message" to view details of an individual message:


You can configure what information is displayed by opening the "File" menu and choosing "Configuration":


Once you have understood these basics, the operation of the tool should be self-explanatory.

Terms of Use; Privacy Policy; Copyright ©2013-2014 (revision 20140418.2d69abc)
 
 
Close
loading
Please Confirm
Close