WebSphere MQ Service Definition

This tutorial show how and why to create an MQ Service Definition.

1. How: open your MQ Explorer window and right click on your service definition entry.

2. Why: an MQ service definition creates an WSDL of your Queues, associated schema to be loaded into WSRR for lookup and dynamic invocation.

Let’s see how it is done:

Step 1: Create a new Service Definition by right clicking on the Service Definition Repository menu and entering a name for your repository.

Step 2: Right click on the newly created Service Definition Repository and select New-> Service Definition

Step 3: Enter the name of the new service definition and also the message Exchange Pattern as One-Way or Request-Response:

Step 4: Create a MQ Service Binding using the MQ Wizard by selecting the Binding Type as:

  1. MQ
  2. SOAP/MQ
Step 5: Provide a operation name for you service definition.
Step 6: Provide the input Destination Name in the following ways: msg/queue/{Queue Name} for Queues or msg/topic/{Topic Name} for Topics.  Provide the request Queue Manager.
Step 7:  Provide the output Destination Name in the following ways: msg/queue/{Queue Name} for Queues or msg/topic/{Topic Name} for Topics.  Provide the response Queue Manager.
Step 8: Click finish to create the new MQ service definition. Click OK.
Step 9: View the newly created service definition by right clicking and selecting View.

4 thoughts on “WebSphere MQ Service Definition

  1. Thanks Thys for the reply.

    I only have IBM websphere Explorer running on my machine.
    The rest of the IBM setup on other machines i am leaving to the professionals.

    I need to interact with the new created webservice on my machine say for instance with java.

    Questions
    1. Does websphere explorer deploy a mini webserver? – what is the base url?
    2. If i try http://localhost:9080/…. I dont get any response!
    3. Or does websphere explorer propegate these settings to the main MQ Server, which then exposes it from the server?

    I need to understand where this new webservice lives – many thanks

  2. Look at this article:
    http://www.ibm.com/developerworks/websphere/library/techarticles/1110_xu1/1110_xu1.html

    A Request Queue will look like this:

    wmq:/msg/queue/CALC.PREMIUM.RESP@INS.PREMIUM.QM?
    connectQueueManager=INS.PREMIUM.QM&channelTableLib=premiumChannelTableLib&
    channelTableName=premiumChannelTableName
    INS.MOTOR.QM
    premiumConnection
    SYSTEM.DEF.SVRCONN
    MQXPT_TCP

    specifies the IP + port of the MQ Queue Manager.

    1. No MQ does not deploy a mini server. What happens is you create a “webservice” or definition that can be registered for searching by other services. The base URL will be the URL of your Queue Manager followed by the port number.

    2. http[s]://hostname:port/WSRR/7.5/Content/bsruri

    http://publib.boulder.ibm.com/infocenter/sr/v7r5/topic/com.ibm.sr.doc/rwsr_rest.html

    3. WebSphere Explorer just creates a WSDL which is a definition of the Queue and registers the interface in WSRR.

    This new service lives in MQ Explorer by WSRR is the new interface to access the service, so other services don’t access MQ directly.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s