I want to receive some messages from IBM MQ based on java. So I write a very simple code to test what I want. Here is the sample code below.
Const.MQ_QMANAGER = "QM.CREDITWEB3T.PC";
Const.MQ_QUEUE_RECEIVE = "MQ.AIRPORTS";
MQSimpleConnectionManager myConnMan = new MQSimpleConnectionManager();
MQQueueManager qMgr = new MQQueueManager(Const.MQ_QMANAGER,
MQJE001: Completion Code '2', Reason '2495'
(1) Your 1st posting is requesting that the connection to the queue manager be in "bindings mode". This means you MUST run the code on the same server where the queue manager is running.
(2) Your 2nd posting is requesting that the connection to the queue manager be in "client mode" (over the network i.e.TCP/IP). This means you can run the code on a remote server and connect to the remote queue manager using the network.