Adding affinities into a workload
For non-Link3270 bridge transactions, affinities are managed by CICSPlex® SM Transaction affinity relation and lifetime fields in the workload management views. You specify these fields to isolate transactions to particular systems and to define affinity types and lifetimes.
Figure 1 illustrates how you might separate the work in a workload based on transaction identifiers and then associate an affinity relation and lifetime with those transactions. With this example, the first occurrence of a transaction named PAY1, where the associated terminal and user names are NET1 and SMITH, respectively, is directed to the appropriate target region within the set of target regions identified as EYUCSG05. The specific target region receiving the transaction and the affinity relation and lifetime associated with the transaction group to which PAY1 belongs are noted. All subsequent occurrences of any transaction in the transaction group that meet the terminal and user name criteria are directed to the same target region for the designated period of time.

- If the transaction is defined to a transaction group, CICSPlex SM notes the match key for that group.
- If the transaction is not part of a transaction group, CICSPlex SM uses the match key from the default transaction group for the workload specification.
- If the terminal and user names associated with the transaction
match the selection criteria specified in an installed workload definition, CICSPlex SM
checks to see if an affinity relation and lifetime are associated
with the transaction group.
- When an affinity relation and lifetime are associated with the
transaction group:
- If it is the first occurrence, CICSPlex SM notes the affinity relation and lifetime. Based on target region availability, CICSPlex SM then selects a target region and directs the transaction to it.
- If it is not the first occurrence, CICSPlex SM routes the transaction to the previously selected target region. As long as the affinity relation and lifetime are applicable, subsequent occurrences of any transaction in the transaction group are directed to the same target region.
- When no affinity relation and lifetime are associated with the transaction group, the transaction is routed to the most appropriate target region in the designated set of target regions.
- When an affinity relation and lifetime are associated with the
transaction group:
- If the terminal and user names do not match the selection criteria, the transaction is routed to the default set of target regions identified in the workload specification. One is selected based on the status of the active target regions in that set.