title: Are there more than one queue manager allowed per host/port?
body: <p>When setting up a <code>MQQueueConnectionFactory</code> we initialize it as follows:</p>
  
  <pre><code>MQQueueConnectionFactory factory = new MQQueueConnectionFactory();
  
  factory.setQueueManager(queueManager);
  
  factory.setTransportType(CommonConstants.WMQ_CM_CLIENT);
  factory.setHostName(host);
  factory.setPort(port);
  factory.setChannel(channel);
  </code></pre>
  
  <p>Especially we set the name of the queue manager. From this pattern it seems that the queue manager name is necessary to fully identify the queue manager. One might concluded that on the same host and port a different queue manager might listen. Is this possible?</p>
  
  <p>However, when setting the <a href="http://www.ibm.com/support/knowledgecenter/en/SSFKSJ_8.0.0/com.ibm.mq.javadoc.doc/WMQJMSClasses/com/ibm/mq/jms/MQConnectionFactory.html?view=kc#setConnectionNameList(java.lang.String)" rel="nofollow noreferrer">the connection name list</a> to specify reconnect targets there is no queue manager name necessary:</p>
  
  <blockquote>
    <p><code>public void setConnectionNameList(java.lang.String hosts) throws javax.jms.JMSException</code></p>
    
    <p>Specifies the hosts to which the client will attempt to reconnect to after its connection is broken. The connection name list is a comma seperated list of host/ip port pairs. eg. 127.0.0.1(1414),host2.example.com(1400) The default setting of this property is 'localhost(1414)' A null, or empty string is taken to mean localhost(1414)</p>
  </blockquote>
  
  <p>When setting the <a href="http://www.ibm.com/support/knowledgecenter/en/SSFKSJ_8.0.0/com.ibm.mq.javadoc.doc/WMQJMSClasses/com/ibm/mq/jms/MQConnectionFactory.html?view=kc#setClientReconnectOptions(int)" rel="nofollow noreferrer">client reconnect options</a> two options seems to be important in this context:</p>
  
  <blockquote>
    <ul>
    <li>WMQ_CLIENT_RECONNECT - Reconnect to the any of the queue managers specified in the connection name list</li>
    <li>WMQ_CLIENT_RECONNECT_Q_MGR - Reconnect to the same queue manager we were originally connected to. This will throw MQRC_RECONNECT_QMID_MISMATCH if the queue manager it tries to connect to (specified in the connection name list) has a different QMID to the queue manager originally connected to.</li>
    </ul>
  </blockquote>
  
  <p>These documentations make not clear if multiple queue managers behind the same host/port are possible. Compare this to Oracle where multiple services can be served by the same listener.</p>
  
  <p>We have two queue managers listening on different hosts/ports which have different names. We want to use one of these queue managers as failover manager in the connection name list. The question is: is the queue manager uniquely identified by host and port only?</p>