104 IMS in the Parallel Sysplex, Volume I: Reviewing the IMSplex Technology
5.3.6 Lock table
The CQS uses the lock table to serialize access to the CQS control queue. The control queue
is currently the only queue that is locked.
The control queue is a CQS private queue that has list entries for functions such as overflow
processing, structure checkpoint, and rebuild processing. When a CQS wants to perform one
of these functions, it must first obtain the lock for the control queue. When it obtains the lock,
it proceeds to look at the list entry for the function that it needs to perform. If the list entry
already contains the name of a CQS, the function is already being performed. Otherwise, this
CQS adds its name, releases the lock on the control queue, and proceeds to perform the
function. When a CQS has its name in the list entry for a particular function, it is referred to as
master CQS
5.3.7 Event monitor controls
The event queue is located in the area of the EMCs and is used to post events of interest to
the connected users. The event queue is maintained by XES in the list structure. There is one
entry in the event queue for each connected user. When a monitored event occurs, an event
monitor control (EMC) is queued to the connector's event queue. EMCs are used to inform
the connector when an event occurs, for example, the arrival of a message on a registered
In this case, the IMS subsystems, represented by CQSs, are the connected users, and the
events they are interested in are the arrival and existence of messages on certain queues.
When IMS registers interest in a queue name (for example, TRANX), TRANX is referred to as
a monitored event. When there is work on the TRANX queue, event monitor control blocks
(EMCs) representing the queue are posted to the event queue for the registered user(s), and
the user is then informed there is work to be done.
The EMCs are 64-byte control blocks which represent a particular user's interest in a
particular queue name. For example, when IMSA registers interest in TRANX, an EMC will be
created for this relationship (IMSA-TRANX). If IMSB also registers interest in TRANX, then
another EMC for IMSB-TRANX will be created.
When an EMC is first posted to the event queue, that client is informed that the queue has
gone from empty to non-empty. The EMC will stay on the event queue for that user until he
either deregisters interest (at which time the EMC is deleted) or the queue becomes empty (at
which time the EMC is just removed from the event queue).
An EMC entry is a control block in the Coupling Facility list structure that is used to represent
a CQS that has a registered interest in a queue. Each EMC entry occupies 64 bytes of
storage. An EMC control block is created for each CQS that has an interest in a particular
queue. If you have three CQSs that register an interest in queue TRANA, three EMCs are
created. Care should be taken when sizing the shared queue structures to ensure that there
is enough space to store the number of EMCs that are required.
CQS reserves 20% of the total structure size for EMCs. If CFCC Level 4 or greater is being
used, the area can be dynamically increased in 5% increments up to a maximum of 50% if
required. Use the
SETXCF ALTER command to make this change. Available data elements are
used to create additional space for EMCs. If the EMC area is increased, the amount of space
available for list entries is reduced. If the EMC area runs out of space, any attempt by an IMS
system to register an interest in a queue fails.
Heres an example of how the EMC looks. When there are multiple entries with the same
queue name (for example, multiple TRANXs) on the queue, they form a sublist. These

Get IMS in the Parallel Sysplex Volume I: Reviewing the IMSplex Technology now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.