Was this helpful?
Websphere MQ Queue
Note:  For general information about Queue Steps, see Queue Step.
WebSphere MQ Queue allows a message to be put into the queue or retrieved from a queue to a message object. Use the PutMessage action to write to the queue. Use the GetMessage action in a Queue step to retrieve messages. Session properties control which message objects are read and the names of the messages that are written, and whether to preserve the message properties.
Supported versions:
DataConnect version <= 11.3.x supports WebsphereMQ client 7.0.0-7.5.x.x using the Websphere MQ 1.0.0 component
DataConnect version >= 11.4.x supports WebsphereMQ client 8.x.x (only) using the Websphere MQ 1.0.0 component
DataConnect version >= 11.5.2 supports IBM MQ >= 9.x.x using the IBM MQ 1.0.0 component
MQ client 8.0.0.2 distributes libraries for versions 2005 and 2012. You can install this version of client then update their path to use either library, depending on which version of Actian DataConnect you need to use.
For more information about the provision of both 2005 and 2012 versions of the native API client libraries in WebSphere MQ 8.0.0.2 and higher, see the following link:
https://www.ibm.com/support/knowledgecenter/SSFKSJ_8.0.0/com.ibm.mq.pro.doc/q130070_.htm
Websphere MQ Queue Properties
Property
Default Value
Description
Format
MQFMT_NONE
WebSphere MQ message format.
Timeout
0
Maximum number of seconds to wait for a message to arrive on a queue when retrieving messages.
Browse
FALSE
Retrieve messages from a queue without removing them.
Convert
FALSE
Converts the message data to a specific character set or numeric encoding. Requires CCSID or Encoding value.
CCSID
MQCSSI_DEFAULT
Character set identifier of the message data.
Encoding
 
Encoding for numeric data. The representation used for binary integers, packed-decimal integers, and floating-point numbers.
Supported Actions
Action
Description
Connect
Establishes a connection to the WebSphere MQ server.
Disconnect
Disconnects from the WebSphere MQ server.
GetMessage
Retrieves message into a message object.
PutMessage
Writes a message object into the queue.
Begin Transaction
Starts a WebSphere MQ transaction.
Commit Transaction
Commits a WebSphere MQ transaction.
Rollback Transaction
Rolls back a WebSphere MQ transaction.
 
Supported Action Properties
Action
Property
Description
PutMessage
GetMessage
Format
WebSphere MQ message format, with allowable values defined by WebSphere MQ
PutMessage
GetMessage
Msgid
Message ID of a specific message put in or retrieve from a queue
PutMessage
GetMessage
Correlationid
Correlation ID of messages to put in or retrieve from a queue
PutMessage
GetMessage
Groupid
Group ID of message to put in or retrieve from a queue
PutMessage
GetMessage
CCSID
Character set that you can convert to. Used with the Convert option
PutMessage
GetMessage
Encoding
Numeric encoding you can convert to. Used with the Convert option
GetMessage
SequenceNumber
Sequence number of a specific message to retrieve from a queue
PutMessage
Offset
Segment offset
PutMessage
ReplyToQ
Reply queue
PutMessage
ReplyToQMgr
Reply queue manage
PutMessage
UserID
User identifier
PutMessage
AccountingToken
Accounting token
PutMessage
ApplIdData
Application identity data
PutMessage
PutAppIName
Application that put the message
PutMessage
PutDate
Date the message was put
PutMessage
PutTime
Time the message was put
PutMessage
ApplOriginData
Application origin data
PutMessage
MsgType
Message type
PutMessage
Expiry
Message lifetime
PutMessage
Feedback
Feedback code
PutMessage
Priority
Message priority
PutMessage
Persistence
Message persistence
PutMessage
BackoutCount
Backout counter
PutMessage
PutApplType
Put application type
PutMessage
MsgFlags
Message flags
PutMessage
OriginalLength
Length of original message
WebSphere MQ Environment Variables
If you use WebSphere MQ environment variables, to ensure compatibility with queue sessions, use the following format:
MQServer=ChannelName/TransportType/IPAddress
Example
MQServer=mymq1/TCP/123.123.123.123
Queue Manager Parameter
Specify the Queue Manager as the Server parameter in the queue session as shown in this example:
Server=<servername> (123.123.123.123) Port=default QueueManager=<queuemanagername> queue=tester1 ServerChannel=serverch1
Server Parameter
The MQServer, MQCHLLIB, and MQCHLTAB environment variables can be changed at runtime or before the GUI tools are launched to test writing to different servers.
In the queue session, there is a Server parameter where you specify a Queue Manager (if you need one).
If you use the MQCHLLIB or MQCHLTAB variable, you must specify the Server parameter.
If you just use the MQServer environment variable, it is not necessary to specify the Server parameter. Instead, just change the MQServer environment variable at run time to specify the new Queue Manager to which you are writing. The MQServer environment variable has the channel, protocol, server, and port specified, which is all that is needed to connect to a different queue manager.
Macro Values for the Server Parameter
You can use macro values for the Server parameter of the session. If you use the MQCHLLIB and MQCHLTAB environment variables, you can create a macro to specify the Queue Manager. The Queue Name cannot use a macro value. Change this before deployment, or use a variable that drives Decision steps to do a Get or a Put message to the proper queue.
It is recommended that you change the MQServer environment variable at runtime, since no Queue Manager is needed in the Server parameter of the queue session. You only need to change the queue name.
Key Points About Websphere MQ and the DJComponent Object
IBM Websphere MQ requires a separate queue manager connection for each thread, and does not permit cross-thread operations.
For processes, three scenarios are possible:
Set MaxConcurrentThreads = 1. All process steps are executed on the same thread, so queue operations can be spread across multiple steps.
Complete all queue operations in a single step. This includes connecting to a queue, getting or putting messages, and completing a transaction. This guarantees that all queue operations are executed in a single thread. Multiple steps can still contains queue operations, but each step is a separate transactional unit of work.
Confine all queue operations to the Start and Stop steps. In multithreaded processes, the Start and Stop steps always execute in the main thread. The Start step can be used to create a connection, begin a transaction and retrieve messages from the queue. The Stop step can be used to write messages to the queue and complete the transaction.
Note:  These threading restrictions apply only to DJComponent objects, not DJMessage objects. The DJMessage objects are completely independent from the messaging systems. So, in scenario 3 above, you can pull a message from a queue in the Start step. Use that message object in multiple concurrent Script or Transformation steps, and complete the transaction in the Stop step. Likewise, you can create DJMessage objects in multiple steps and write all of the message objects to a queue in the Stop step. The maximum size limit for DJMessage is 2 GB.
Last modified date: 02/09/2024