Data Transformation Engine IBM WebSphere MQ Adapter Reference Guide

Chapter 3 - IBM WebSphere MQ Commands List of Commands
IBM WebSphere MQ Adapter Reference Guide
45
Refresh Message Cursor (-REFRESH)
Use the Refresh Message Cursor adapter command (-REFRESH) to ensure that
higher-priority messages are enqueued in front of any existing messages with a
lower priority so that the higher-priority messages can trigger the associated
maps to run. This command is only used when using an IBM WebSphere MQ event
input with the Event Server. If messages of a higher priority are enqueued after
messages of a lower priority, the default behavior is that the higher priority
messages would not trigger the maps.
-REFRESH [
reset_time
]
Option Description
reset_time
This is a non-negative integer defining the number of
seconds that elapse before the message cursor is reset to
the head of the queue
The Refresh Message Cursor adapter command (-REFRESH) resets the message
cursor of the source queue message event listener to the head of the queue after
every listener cycle (detection of all messages currently on the queue) is
completed. You can optionally specify a non-negative integer argument
(
reset_time
) that defines the number of seconds that elapse before the messages
cursor is reset to the head of the queue. If
reset_time
is set to zero, the message
cursor will be constantly reset to the beginning of the queue after each event.
Thus, the higher priority messages are processed as soon as possible. However,
frequent repositioning of the cursor will degrade overall performance.
The Refresh Message Cursor adapter command (
-REFRESH) is only needed when
using an IBM WebSphere MQ event input with the Event Server, and only in two
specific situations:
When messages of higher priority are placed at the beginning of the queue that
are not recognized because the message cursor has already begun moving
towards the bottom of the queue.
When there is a possibility of the message cursor skipping the uncommitted
messages on the queue. As an example, suppose that two applications, APP1
and APP2, simultaneously place messages on an empty queue and the
following sequence of operations occurs (a possibility because APP1 and APP2
are independent and are executing concurrently):
T0: APP1 PUT(M1)
T1: APP2 PUT(M2)
T2: APP2 COMMIT(M2)
T3: APP1 COMMIT(M1)