How to connect to IBM MQ Manager with HA configuration?

I am writing a C # client that connects to IBM Websphere MQ Manager using amqmdnet.dll using the following construct:

_myQueueManager = new MQQueueManager(queueManagerName, properties);

In the Hashtable properties, I set the host name, channel, and queuemanager. Now, how can I use the auto-reconnect feature in my client application? We have a multi-instance IBM MQ instance queue manager HA configuration.

Basically, do I have four endpoints to which I should step back in case of a connection failure from my client?

+4
source share
1 answer

According to the documents :

MQQueueManager (String queueManagerName, Hashtable ), CONNECTION_NAME_PROPERTY.

:

ConnectionName = "fred.mq.com(2344),nick.mq.com(3746),tom.mq.com(4288)";
Hashtable Properties-new Hashtable();
properties.Add(MQC.CONNECTION_NAME_PROPERTY,ConnectionName);
MQQueueManager qmgr=new MQQueue Manager("qmgrname",properties);

. , . , , . , .

.NET, , / .

+5

Source: https://habr.com/ru/post/1669039/


All Articles