How CICSPlex SM WLM chooses where to route work

When a transaction is initiated, CICSPlex® SM uses algorithms to weigh up the factors that contribute to a routing decision and select the target region that is likely to deliver the best performance. There are four algorithms. You specify a default routing algorithm on the workload specification. You can choose to override this default for a transaction group by specifying a different routing algorithm on the transaction group definition.

The four routing algorithms

CICSPlex SM uses one of the following four algorithms to determine which target region processes the work:

If any transaction affinities are outstanding for the transaction that is being routed, the affinity target region is selected, regardless of the algorithm used.

You specify a default routing algorithm on the workload specification (WLMSPEC). Optionally, you can specify a routing algorithm at the transaction group (TRANGRP) level. An algorithm that is specified at the transaction group level overrides the default algorithm that is associated with the workload specification.

To change the default routing algorithm on the workload specification for a running workload, you must shut down all of the CICS regions that are associated with the workload. This refreshes the workload. You can change the routing algorithm on the transaction group dynamically. You do not have to shut down the CICS region.

Note:

You might see the use of a particular algorithm described as a routing mode: for example, goal routing mode (or even more simply, goal mode) to describe a configuration that uses the goal algorithm.

Queue algorithm
This is the most commonly used algorithm. If the transaction that is being routed has no active affinities, this algorithm distributes the workload across a set of target regions. Selection criteria include the current task load, the health state, and the type of connection between the router and the target region.
If the transaction that is being routed has no active affinities, the queue algorithm causes CICSPlex SM to select the target region that conforms to the following set of criteria:
  • The region has the shortest queue of work waiting to be processed, relative to the maximum number of tasks permitted in the target region. This queue of work, also called the load count, is the count of all active and queued user tasks. By default, tasks queued for both MAXTASKS and TRANCLASS attributes are included in the load count. Use of the "Task load queue mode" attribute in the CSYSDEF resource table allows sites to exclude tasks queued for the TRANCLASS attribute from the load count. For more information about the "Task load queue mode" attribute in the CSYSDEF resource table, see CICS® system definitions - CSYSDEF.
  • The region is the least affected by conditions such as short-on-storage, SYSDUMP, and TRANDUMP.
  • The region is the least likely to cause the transaction to stop.
  • The region is the shortest path for inter-region communication.
  • The region has a z/OS® WLM health value in the range 1-100 (see The z/OS WLM health state of the region, only when the z/OS WLM health service is on.).
Goal algorithm
This algorithm selects the target region based on a predefined goal for response time. If the goal algorithm does not identify a target region, the queue algorithm is applied to the remaining target regions. Success with this algorithm depends on setting appropriate and achievable response time goals. Failing to define appropriate response time goals can result in unexpected routing patterns.

Goal mode is better suited to users with experience of CICSPlex SM WLM who use a single LPAR and have very specific requirements around response time goals.

Link neutral queue algorithm
The link neutral queue algorithm works like the queue algorithm, except that the type of connection between the routing and target region is not considered. The connection type weighting is ignored.

Like the queue algorithm, this algorithm can accommodate differences in processor power and different maximum task values in the target regions. However, it does not allow for communications link speeds between the router and a target. Compared to the queue algorithm, this algorithm might spread a workload across a target scope more evenly, but the workload might not complete as quickly.

Be cautious about setting the default routing algorithm on the workload specification to one of the link neutral algorithms because it will apply to every dynamic transaction. If you want the fastest transactions to continue to be processed locally but you want dynamic transactions that request services from MVS subsystems to be processed anywhere, consider the queue algorithm as the default routing algorithm on the workload specification. Then apply the link neutral algorithm to a subset of transactions at the transaction group level.

Link neutral goal algorithm
The link neutral goal algorithm works like the goal algorithm, except that the type of connection between the routing and target region is not considered. The connection type weighting is ignored.

Be cautious about setting the default routing algorithm on the workload specification to one of the link neutral algorithms because it will apply to every dynamic transaction. If you want the fastest transactions to continue to be processed locally but you want dynamic transactions that request services from MVS subsystems to be processed anywhere, consider the queue algorithm as the default routing algorithm on the workload specification. Then apply the link neutral algorithm to a subset of transactions at the transaction group level.

Factors that contribute to CICSPlex SM dynamic workload routing decisions

Each factor that contributes to a workload routing decision is given a weighting by CICSPlex SM. Usually, the target region with the lowest weighting after all factors are considered is selected for routing. If all available target regions have equal weightings and are, therefore, assessed as being equally capable of running the work, a target region is selected randomly from the group. So, in systems that are lightly loaded, there is no predetermined order in which work is allocated to equally capable target regions.

The number of tasks in the region
Factored as a percentile value, which is calculated by dividing the target region MAXTASKS setting with the current task count.
The health status of the region
Factored by assigning arithmetic weights, depending on whether the region is short-on-storage, taking a transaction dump, taking a system dump, running at its MAXTASKS limit, in a non-responsive state, or in a CICSPlex SM stall.
Note: Health is assessed independently of system availability monitoring (SAM) and is not influenced by SAM settings.
Connection type (link) between the routing region and the target region
Factored by assigning arithmetic weights, depending on whether the target region is linked to the target by an MRO connection, an XCF connection, an LU6.2 connection, an IPIC connection, or if the target region is the router itself. The connection type is not used by the two link-neutral algorithms.
Weight is allocated to each connection in the following order of priority:
  1. Local
  2. MRO/IRC and MRO/XM (local LPAR)
  3. MRO/XCF (remote LPAR)
  4. IPIC (local LPAR)
  5. IPIC (remote LPAR)
  6. LU6.2
  7. Indirect
For example, if all other factors are equal, a target region that is connected to its requesting region by using MRO/XCF is preferred (that is, it has the lowest weighting allocated) to a target region that is connected by using IPIC. IPIC connections between routing and target regions in the same LPAR have a lower weighting than IPIC connections to target regions in a different LPAR, so that if other factors are equal, local IPIC connections are preferred to remote IPIC connections.
The z/OS WLM health state of the region, only when the z/OS WLM health service is on.
Factored by assigning penalizing weights, depending on the z/OS WLM health value of a region provided by the z/OS WLM health service. The z/OS WLM health state of a region is reflected by a z/OS WLM health value in the range 0 - 100:
  • A region with a z/OS WLM health value of zero is not eligible to receive work. CICSPlex SM WLM does not route work to this region. Any workload affinities that are associated with this region remain and are honored; however, workload routing based on those affinities fails while the health value is zero, and results in either message EYUWR0003W or a SYSIDERR condition. Message EYUWR0003W indicates that the EYU9WRAM program was in effect and the affinity AOR was not available. To resolve such routing failures, initiate a warm-up for the region so that the health value is non-zero, and then rerun your workload. See Initiating a CICS system warm-up.
  • For a region with a z/OS WLM health value in the range 1 - 99, penalizing weights are assigned in the routing algorithm. The greater the health value, the lower the penalizing weight. So, target regions with a greater health value are more favorable in the routing decision. A region that is assigned a high penalizing weight remains active and might still receive work if no other healthier regions are available in the same scope.
  • A region with a z/OS WLM health value of 100 is not assigned with penalizing weights and is fully capable of receiving work.

During the CICS warm-up or cool-down process, CICS adjusts the z/OS WLM health value of the region. This affects the routing decision of CICSPlex SM WLM, which restricts workload into the region during that process. In general, when a region is warming up, its health value increases periodically, and the region might gradually receive a larger workload; when a region is cooling down, its health value decreases periodically, and the region might gradually receive less work until it becomes ineligible as a target. For more information about what happens during CICS warm-up or cool-down, see CICS warm-up and cool-down by use of z/OS Workload Manager health service.

You can deliberately make a region ineligible as a workload routing target in CICSPlex SM routing decisions by setting its z/OS WLM health open status to CLOSE in the MVS workload management (MVSWLM) view. This gradually makes the region less favorable until the region's z/OS WLM heath value drops to 0, indicating that the region becomes ineligible. Additionally, you can change a region's z/OS WLM heath value to zero immediately, by setting its z/OS WLM health open status to IMMCLOSE.

Outstanding CICSPlex SM Realtime Analysis (RTA) Events that are associated with the workload, if any
Factored by assigning arithmetic weights that depend on the severity of the events outstanding. These events are factored in only when Event name is specified in the WLM specification for the workload or any Transaction Group definitions that are associated with it.
Any transaction affinities, if any, that are outstanding to override the dynamic routing decision
Regardless of any other factors, if the routing request has an outstanding affinity associated with it, that affinity always overrides the route decision.