Home

 

ConnectionId (MQBYTE24)

This output parameter is a unique 24-byte identifier that allows MQ to reliably identify an application. An application can use this identifier for correlation in PUT and GET calls.

The queue manager assigns a unique ID to all connections, however they are established. If an MQCONNX establishes the connection with a version 5 MQCNO, the application can determine the ConnectionId from the returned MQCNO. The assigned identifier is guaranteed to be unique among all other identifiers that MQ generates, such as CorrelId, MsgID, and GroupId.

Use the ConnectionId to identify long running units of work using the PCF command Inquire Connection or the MQSC command DISPLAY CONN. The ConnectionId used by MQSC commands (CONN) is derived from the ConnectionId returned here. The PCF Inquire and Stop Connection commands can use the ConnectionId returned here without modification.

We can use the ConnectionId to force the end of a long running unit of work, by specifying the ConnectionId using the PCF command Stop Connection or the MQSC command STOP CONN. See WebSphere MQ Programmable Command Formats and Administration Interface and WebSphere MQ Script (MQSC) Command Reference for more information on using these commands.

The initial value of this field is 24 null bytes in all programming languages.

This field is not returned if Vis less than MQCNO_VERSION_5.

The length of this field is given by MQ_CONNECTION_ID_LENGTH.



 

Home