IBM MQ

Frends.IBMMQ.GetMessages / 2.0.0

Summary

Takes messages off a queue, removing them, and can do so inside a transaction so an unhandled failure returns them rather than losing them. Message properties, descriptors and RFH2 headers can come along with the body.

Typical use — reliable consumption from MQ, where the transaction is what makes a failed Process safe to retry

Details

Frends version
5.7 and newer
Agent
Crossplatform
Target framework
net8.0

Input parameters.

Name Type Default Example Description
UseTransaction Boolean True true

Use transaction when getting messages. If true, when getting multiple messages one by one from the queue they are rolled back in case there is an error or the task is cancelled.

TransactionType TransactionType Required TransactionType.Required

Transaction type. Required: A transaction is required by the scope. It uses an ambient transaction if one already exists. Otherwise, it creates a new transaction before entering the scope. RequiresNew: A new transaction is always created for the scope.

Possible values:

  • Required: A transaction is required by the scope. It uses an ambient transaction if one already exists. Otherwise, it creates a new transaction before entering the scope. This is the default value.

  • RequiresNew: A new transaction is always created for the scope.

TransactionTimeout Int32 60 60

Transaction timeout used, default is 60 seconds.

MessageCount Int32 1 1

Maximum number of messages to get.

MessageAsBytes Boolean False false

If set to true, message contents are returned as a byte array.

GetMessageProperties Boolean True true

Return Message properties in addition to the actual message.

GetMessageDescriptor Boolean False false

Return Message descriptor information in addition to the actual message.

ParseRFH2Header Boolean False false

Return and strip RFH2 headers from the beginning of the message so that they won't be seen in the actual message. RFH2 headers may be present in the message if the sender has written them. This can be set to true with no ill effect even if the message doesn't have RFH2 headers.

An unhandled error has occurred. Reload 🗙