Connect webMethods to WebSphere MQ as JMS provider

Copy the following files from MQ installation directory to WM integration server directory (IntegrationServer\lib\jars):

WebSphereMQ\java\lib\com.ibm.mq.commonservices.jar
WebSphereMQ\java\lib\com.ibm.mq.headers.jar
WebSphereMQ\java\lib\com.ibm.mq.jar
WebSphereMQ\java\lib\com.ibm.mq.jmqi.jar
WebSphereMQ\java\lib\com.ibm.mq.pcf.jar
WebSphereMQ\java\lib\com.ibm.mqjms.jar
WebSphereMQ\java\lib\dhbcore.jar
WebSphereMQ\java\lib\mqcontext.jar

mqcontext.jar can be found in github.com while other jars provided by IBM by default installation.
https://github.com/khaliqgaffar/jboss_esb_eval_proj/blob/master/AuditMonitor/esbcontent/lib/mqcontext.jar

Restart webMethods integration server.

Setup new TCPIP listener in MQ and start it.
MQ.Add Listener

Add JNDI service provider in MQ as JMS administered objects MQ
Provider URL: servername:port/SYSTEM.DEF.SVRCONN (port is the one created in step 3)
Initial Context Factory: com.ibm.mq.jsm.context.WMQInitialContextFactory
Required Libraries: mqcontext.jar
Connect this context factory.
mq-add-jndi.jpg

Add MQ Connection Factory.
Make sure you select “Connection Factory” as type to view both Queue and Topic.
MQ.Add Factory

Add JNDI service provider in webMethods.
Under IS Admin – Setting — Messaging – JNDI Settings – Create JNDI Provider Alias.
mq-add-jndi-provider.jpg
Test JNDI Provider:
MQ.Test JNDI Provider

Add JMS Connection Alias in webMethods.
Under IS Admin – Setting — Messaging – JMS Settings – Create JMS Connection Alias.
JNDI Provider Alias: MQProvider (JNDI created in step 6)
Connection Factory Lookup Name: DEFAULT (Connection factory created in step 5)
MQ.Add JMS Connection
Enable the JMS connection.

Send JMS message from webMethods to MQ use service pub.jms:send
MQ.JMS send

Retrieve JMS message from MQ use JMS trigger
MQ.JMS trigger

2 thoughts on “Connect webMethods to WebSphere MQ as JMS provider

  1. Ram

    Hi, Thanks for your post. I couldnt get mqcontext.jar from IBM website and also from your link. Can you share that jar link please?

    Like

    Reply

Leave a reply to Ram Cancel reply