Red Hat DocumentationFuse Message BrokerToggle FramesPrintFeedback

SelectorTalk Application

What the sample does

The SelectorTalk sample applications are similar yet consistent with the behavior of the messaging model. The SelectiveTalkers both send and receive on Q1. The Talkers do not specify selection parameters.

Running the sample

To run the SelectorTalk sample do the following:

  1. In window 1, enter ant filtertalk1.

  2. In window 2, enter ant filtertalk2.

  3. In window 3, enter ant talk2.

    Talker_2 sends to Q2 and receives on Q1.

  4. In the SelectiveTalker_1 window, enter some text and then press Enter. Send a few messages in this window.

    The messages are displayed in either that window or the Talker_2 window (usually alternately.)

  5. In the SelectiveTalker_2 window, enter some text and then press Enter. Send a few messages in this window.

    The messages are displayed in either that window or the Talker_2 window (usually alternately.)

  6. In the Talker_2 window, enter some text and then press Enter.

    None of the windows receives the message. Talker_2 is receiving on Q2. The selective talkers are receiving on Q1, but they are qualifying their selection as only messages that have the specified property, and, at that, set to their preferred value. So the message will be stored in Q1 even though there are receivers on Q1.

  7. In window 3, press Ctrl+C to stop Talker_2.

  8. In window 3, enter ant talk1.

    Talker_1 sends to Q2 and receives on Q1. When it starts, it immediately receives the messages stored on Q1 (unless they have expired.)

Stopping the sample

To stop the applications press Ctrl+C in each window.

Comments powered by Disqus