Configuring the queue manager and broker for an application that connects to a IBM WebSphere MQ queue manager

This section assumes that you are using IBM® WebSphere® MQ version 7.0. Before you can run an application that connects to a IBM WebSphere MQ queue manager, you must configure the queue manager. For a publish/subscribe application, some additional configuration is required if you are using Queued publish/subscribe interface.

Before you begin

XMS works with WebSphere Message Broker version 6.1 or earlier.

Before starting this task, you perform the following steps:

  • Make sure that your application has access to a queue manager that is running.
  • If your application is a publish/subscribe application and uses Queued publish/subscribe interface, make sure that "PSMODE" attribute is set to "ENABLED" on the queue manager.
  • Make sure that your application uses a connection factory whose properties are set appropriately to connect to the queue manager. If your application is a publish/subscribe application, make sure that the appropriate connection factory properties are set for using the broker. For more information about the properties of a connection factory, Properties of ConnectionFactory.

About this task

You configure the queue manager and broker to run XMS applications in the same way that you configure the queue manager and queued publish/subscribe interface to run WebSphere MQ JMS applications. The following steps summarize what you need to do.

Procedure

  1. On the queue manager, create the queues that your application needs.

    For information about how to create queues, see the Defining queues topic in the WebSphere MQ product documentation.

    If your application is a publish/subscribe application and uses Queued publish/subscribe interface that needs access to IBM WebSphere MQ classes for JMS system queues, wait until Step 4a before creating the queues.

  2. Grant the user ID associated with your application the authority to connect to the queue manager, and the appropriate authority to access the queues.

    For information about authorization, see the Security section of the IBM WebSphere MQ product documentation. If your application connects to the queue manager in client mode, see also the Clients topic in the IBM WebSphere MQ product documentation.

  3. If your application connects to the queue manager in client mode, make sure that a server connection channel is defined at the queue manager and that a listener is started.

    For information about how to do this, see the Clients topic in the IBM WebSphere MQ product documentation.

    You do not need to perform this step for each application that connects to the queue manager. One server connection channel definition and one listener can support all the applications that connect in client mode.

  4. If your application is a publish/subscribe application, and uses Queued publish/subscribe interface, perform the following steps.
    1. On the queue manager, create the IBM WebSphere MQ classes for JMS system queues by running the script of MQSC commands that are supplied with IBM WebSphere MQ. Make sure that the user ID associated with the WebSphere Message Broker has the authority to access the queues.

      For information about where to find the script and how to run it, see the Using Java™ topic in the WebSphere MQ product documentation.

      Perform this step only once for the queue manager. The same set of IBM WebSphere MQ classes for JMS system queues can support all XMS and IBM WebSphere MQ classes for JMS applications that connect to the queue manager.

    2. Grant the user ID associated with your application the authority to access the IBM WebSphere MQ classes for JMS system queues.

      For information about what authorities the user ID needs, see the Using Java topic in the IBM WebSphere MQ product documentation.

    3. For a broker of WebSphere Event Broker or WebSphere Message Broker, create and deploy a message flow to service the queue where applications send messages that they publish.

      The basic message flow comprises an MQInput message processing node to read the published messages and a Publication message processing node to publish the messages.

      For information about how to create and deploy a message flow, see the WebSphere Event Broker or WebSphere Message Broker product documentation.

      You do not need to perform this step if a suitable message flow is already deployed at the broker.

Results

You can now start your application.