Red Hat DocumentationFuse Message BrokerToggle FramesPrintFeedback

MessageMonitor Application

What the sample does

The MessageMonitor sample application provides an example of a supervisory application with a graphical interface. By subscribing with the wildcard syntax used in the HierarchicalChat, the monitor gets messages on all topics in the topic hierarchy. The application listens for any message activity, and then displays each message in its window.

Running the sample

To start the MessageMonitor sample, enter ant tmonitor in window 3.

The MessageMonitor Java window opens.

To send messages to the MessageMonitor do the following:

  1. In window 1, enter ant chat1, then type Hello, and press Enter.

    The message displays in the MessageMonitor window, noting that the message was received on the jms.samples.chat topic

  2. In window 2, enter ant durable1, then type Hello, and press Enter.

    The message displays in the MessageMonitor window, noting that the message was received on the jms.samples.durablechat topic.

    Because the MessageMonitor subscribes to the topic jms.samples.*, messages are received from both publishers. The Chat and DurableChat applications subscribe only to their respective topics.

  3. Click the Clear button to empty the listed messages.

Stopping the sample

To stop the applications, press Ctrl+C in each of the windows.

Comments powered by Disqus