ExitResponse (MQLONG)
This field specifies the response from the exit.
This field is set by the exit to communicate with the MCA. It must be one of the following values:
- MQXCC_OK
- Exit completed successfully.
- For the channel security exit, this value indicates that message transfer can now proceed normally.
- For the channel message retry exit, this value indicates that the MCA must wait for the time interval returned by the exit in the MsgRetryInterval field in MQCXP, and then try the message again.
- MQXCC_SUPPRESS_FUNCTION
- Suppress function.
- For the channel security exit, this value indicates that the channel must be terminated.
- For the channel message exit, this value indicates that the message is not to proceed any further towards its destination. Instead the MCA generates an exception report message (if one was requested by the sender of the original message), and places the message contained in the original buffer on the dead-letter queue (if the sender specified MQRO_DEAD_LETTER_Q), or discards it (if the sender specified MQRO_DISCARD_MSG).
For persistent messages, if the sender specified MQRO_DEAD_LETTER_Q, but the put to the dead-letter queue fails, or there is no dead-letter queue, the original message is left on the transmission queue and the report message is not generated. The original message is also left on the transmission queue if the report message cannot be generated successfully.
The Feedback field in the MQDLH structure at the start of the message on the dead-letter queue indicates why the message was put on the dead-letter queue; this feedback code is also used in the message descriptor of the exception report message (if one was requested by the sender).
- For the channel message retry exit, this value indicates that the MCA does not wait and try the message again; instead, the MCA continues immediately with its normal failure processing (the message is placed on the dead-letter queue or discarded, as specified by the sender of the message).
- For the channel auto-definition exit, either MQXCC_OK or MQXCC_SUPPRESS_FUNCTION must be specified. If neither of these values is specified, MQXCC_SUPPRESS_FUNCTION is assumed by default and the auto-definition is abandoned.
This response is not supported for the channel send and receive exits.
- MQXCC_SEND_SEC_MSG
- Send security message.
This value can be set only by a channel security exit. It indicates that the exit has provided a security message which must be transmitted to the partner.
- MQXCC_SEND_AND_REQUEST_SEC_MSG
- Send security message that requires a reply.
This value can be set only by a channel security exit. It indicates
- that the exit has provided a security message which can be transmitted to the partner, and
- that the exit requires a response from the partner. If no response is received, the channel must be terminated, because the exit has not yet decided whether communications can proceed.
- MQXCC_SUPPRESS_EXIT
- Suppress exit.
- This value can be set by all types of channel exit other than a security exit or an auto-definition exit. It suppresses any further invocation of that exit (as if its name had been blank in the channel definition), until termination of the channel, when the exit is again invoked with an ExitReason of MQXR_TERM.
- If a message retry exit returns this value, message retries for subsequent messages are controlled by the MsgRetryCount and MsgRetryInterval channel attributes as normal. For the current message, the MCA performs the number of outstanding retries, at intervals given by the MsgRetryInterval channel attribute, but only if the reason code is one that the MCA would normally retry (see the MsgRetryCount field described in MQCD - Channel definition ). The number of outstanding retries is the value of the MsgRetryCount attribute, less the number of times the exit returned MQXCC_OK for the current message; if this number is negative, no further retries are performed by the MCA for the current message.
- MQXCC_CLOSE_CHANNEL
- Close channel.
This value can be set by any type of channel exit except an auto-definition exit.
If sharing conversations is not enabled, this value closes the channel.
If sharing conversations is enabled, this value ends the conversation. If this conversation is the only conversation on the channel, the channel also closes.
This field is an input/output field from the exit.