Module 8: CICS Program and Data Passing
Pseudo-Conversational Programming
Conversational vs pseudo-conversational
- In a conversational program, the task stays alive while the user thinks and types.
- The program issues RECEIVE and waits. All its storage and resources stay locked during the wait.
- This wastes resources. A user thinking for two minutes holds storage, enqueues and file locks for two minutes.
- In a pseudo-conversational program, the task ends after each screen interaction.
- The program saves its state in a COMMAREA or channel and issues RETURN TRANSID.
- When the user presses a key, CICS starts the program again and passes the saved state back.
- To the user it looks conversational. To CICS it is a series of short tasks. That is why it is called pseudo-conversational.
How pseudo-conversational processing works
Rules for pseudo-conversational programs
- Always check EIBCALEN at the start to know if this is the first execution.
- Keep the COMMAREA small. Store only state data like screen counts and keys, not whole records.
- Release enqueues before RETURN TRANSID so other tasks are not blocked during think time.
- Re-read any record you plan to update, because another task may have changed it while the user was thinking.
- The TRANSID on RETURN must be defined in the PCT.
MainframeBug Assistant