DefReconnect ( MQLONG)

The DefReconnect channel attribute sets the default reconnection attribute value for a client connection channel.

The default automatic client reconnection option. We can configure a IBM MQ MQI client to automatically reconnect a client application. The IBM MQ MQI client tries to reconnect to a queue manager after a connection failure. It tries to reconnect without the application client issuing an MQCONN or MQCONNX MQI call.

Reconnection is an MQCONNX option. By using the DefReconnect channel attribute we can add reconnection behavior to existing applications that use MQCONN. We can also change the reconnection behavior of applications that use MQCONNX.

We can also set the DefRecon value from the mqclient.ini file to set or modify reconnection behavior. The DefRecon value from the mqclient.ini file takes precedence over the DefReconnect channel attribute.


Syntax

DefReconnect ( MQRCN_NO|MQRCN_YES|MQRCN_Q_MGR| MQRCN_DISABLED )


Parameters

    MQRCN_NO
    MQRCN_NO is the default value.

    Unless overridden by MQCONNX, the client is not reconnected automatically.

    MQRCN_YES
    Unless overridden by MQCONNX, the client reconnects automatically.

    MQRCN_Q_MGR
    Unless overridden by MQCONNX, the client reconnects automatically, but only to the same queue manager. The QMGR option has the same effect as MQCNO_RECONNECT_Q_MGR.

    MQRCN_DISABLED
    Reconnection is disabled, even if requested by the client program using the MQCONNX MQI call.

Automatic client reconnection is not supported by IBM MQ classes for Java.

DefReconnect Reconnection options set in the application
  MQCNO_RECONNECT MQCNO_RECONNECT_Q_MGR MQCNO_RECONNECT_AS_DEF MQCNO_RECONNECT_DISABLED
MQRCN_NO YES QMGR NO NO
MQRCN_YES YES QMGR YES NO
MQRCN_Q_MGR YES QMGR QMGR NO
MQRCN_DISABLED NO NO NO NO
Parent topic: Fields


Related reference


Related information