Tuesday, 26 March 2019

How do CICS transactions works? | IBM-CICS Transaction Flow.

CICS transactions flow
CICS Transactions Flow

Almost everybody uses banking service daily and most of the big bank run on the mainframe. As per statistics, CICS handles millions of transaction per seconds.

Whenever you swipe your ATM / Credit card front-end system (i.e. POS machine) initiate corresponding CICS transaction to complete the required transactions.

"Walmart runs an average of 500 million transactions per day on CICS"

In CICS each transaction is identified by a unique, four−character identifier called a transaction identifier or trans−id. To initiate a transaction, the user enters its transaction identifier or trans-id at a terminal.

A user cannot directly invoke a program. Instead, the user invokes a transaction, which in turn specifies the application program to be run. When a user invokes a transaction, CICS locates the application program associated with the transaction, loads it into storage, and starts a task.

In the below diagram, User trigger transaction from the terminal by typing trans id - INQ1, CICS service check PCT and PPT tables to locates the program associated with the trans id and loads the program it into storage/memory, and starts a task.

The difference between a task and a transaction is that while several users may invoke the same transaction, each is given a separate task.  

Transaction Flow
IBM-CICS Transaction Flow


All transactions are defined in a CICS table called the Program Control Table (PCT). Each trans−id in the PCT identifies the program CICS should execute when the transaction is invoked.

Programs associated with the transaction are defined in the Processing Program Table (PPT). This table keeps track of which programs are already loaded into storage. If a program has not been loaded into storage, it's loaded when its associated transaction is invoked.

In addition to PCT and PPT table, CICS use other important table's to run a transaction. To create these definitions, a systems programmer can use a batch program for that purpose or an interactive program called Resource Definition Online (RDO). Programmer normally used CEDA commands to create resource definitions. 

No comments:

Post a comment