Debug: putting a test message on an input queue

You can put a message on an input queue to test a message flow that you are debugging.

Before you begin

Complete the steps described in Attaching the flow debugger to an integration server for debugging.

About this task

If your message flow includes MQInput and MQOutput nodes, you can test the flow by putting a message on the input queue of your first MQInput node.

You can use the command line interfaces or WebSphere® MQ Explorer to put a message to a queue.

Note: It is not possible to use the Flow debugger with the Flow Exerciser.
You can also use the Test Client as a repeatable alternative. To use the Test Client, complete the steps described in the following sections.
Note: The Test Client is not enabled by default. To use the Test Client, you must enable this facility in the Test Client preferences; see Test Client preferences.

If the message is processed by the message flow and is put on an output queue, you can retrieve it from that queue. See: Debug: getting a test message from an output queue.

Using enqueue in the Test Client

About this task

To configure an enqueue event in the Test Client so that you can use it to send a test message:

Procedure

  1. Switch to the Integration Development perspective.
  2. Open your message flow in the Message Flow editor.
  3. Right-click the input node of the message flow and click Test.
    The message flow is deployed and the Test Client editor opens and displays the Events window.
  4. On the toolbar of the Test Client editor, under Message Flow Test Events, click the Enqueue icon Enqueue icon.
  5. Under Detailed Properties, enter the names of the queue manager and the queue for the input node for this flow.
    Queue manager names are case-sensitive; make sure that you enter the name correctly.

    If you are putting a message onto an input queue that is on a remote computer, ensure that the queue manager of the associated integration node has a server-connection channel called SYSTEM.BKR.CONFIG.

  6. If you are putting a message onto a remote queue, enter values to identify the host and port of the computer that is hosting the queue.
  7. Optional: If you want to save the Test Client file, complete the following steps:
    1. Click File > Save and select the project where you want to save the file.
    2. Enter a name for the file and click Finish.
    The Test Client file is saved in the Flow Tests folder in the project.

Adding data to your message

About this task

If you want to add just a small amount of test data in your test message, type the data into the Source section of the Message pane:

Procedure

  1. Open your Test Client file.
  2. Type your test data directly into the Source section of the Message pane.
  3. Put the test message by clicking Send Message.

Optional: Using a file of sample data

About this task

If you want your test message to contain a larger quantity of sample data (for example some structured XML), you can import a file containing that data into the Test Client:

Procedure

  1. In the Events tab of your Test Client file, click Import Source.
  2. Select the file you want to use as the content for the test message, and click Open.
    The contents of the selected file is added to the Source pane.
  3. Click File > Save when you have finished.
  4. Put the test message by clicking the Send Message button.