Sessions that persist at CICS startup
These tasks and modules are involved when z/OS® Communications Server persistent sessions are restored on a CICS® restart.
Summary
- Task CGRP runs DFHZCGRP.
- DFHZCGRP calls DFHZGRP.
- DFHZGRP issues a VTAM® INQUIRE instruction.
- DFHZGRP performs one of the following actions:
- Terminates session via DFHZGUB issuing CLSDST/TERMSESS.
- Restores the session with OPNDST TYPE=RESTORE.
- DFHZGRP queues restored sessions for further processing.
- DFHZGRP issues RECEIVE_ANY commands.
- DFHZGRP does some CNOS work.
- DFHZGRP does some URD work.
- Queued sessions are restored.
More detail
- Attach task CGRP - program DFHZCGRP in DFHSII1 after TCRP is attached.
- DFHZCGRP calls DFHZGRP with a START_TYPE of one of the following:
- COLD
- WARM
- EMER_XRF
- EMER
- DFHZGRP issues VTAM INQUIRE instructions in chunks; that is, z/OS Communications Server is passed
an area with a size defined in the TCT prefix.
The area is filled with NIBs by z/OS Communications Server. DFHZGRP scans the NIBs and determines whether to UNBIND or OPNDST each session.
For COLD, WARM, and EMER_XRF, all sessions are unbound.
For EMER, some sessions are unbound and some restored depending on the circumstances.
- Restored sessions are queued to DFHZACT for further processing by DFHZXRC or DFHZXPS.
- RECEIVE_ANY initialization done.
- CNOS records are processed by making calls to DFHZGPC.
- URDS are reset to AWAITING RE_SYNCHRONIZATION for EMER only.
- DFHZACT calls DFHZXRC or DFHZXPS for each session queued by DFHZGRP.
Task and module flow diagram
-> indicates an ATTACH
TASK
TCRP
1 TCP III CSSY CGRP
--- --- ---- ----
.
.
SII1->ZCSTP
ZDSP
.ZSLS
. ZGSL
Spin on
TCTV_RA_DONE
.
SII1---------->SII1 --->TCRP
SII1-----------------> ZCGRP
. . . install .ZGRP
. . . TCTTEs . INQUIRE on
. . . etc . persistent sessions
. . . . wait on TCTVCECB (EMER)
. . . Post TCTVCECB
. . task end .
. . . process persistent
. . . sessions
. . . RECEIVE_ANY processing
ZDSP continues <------------------- set TCTV_RA_DONE
. post TCTV_ZGRP_FIN_ECB
. task end
. Wait on
. TCTV_ZGRP_FIN_ECB
SIJ1
. SETLOGON START
. Start CXRE task
. Control is Given to CICS
ZACT
. ZXRC
. ZXPS
Task and module flow: more detail
- Startup runs as normal until DFHSII1 has started the TCP (CSTP) task and DFHZDSP runs.
- DFHZDSP calls DFHZSLS.
- If z/OS Communications Server is at V3R4.1 or later, DFHZSLS calls DFHZGSL to issue SETLOGON OPTCD=PERSIST if the value of the system initialization parameter PSDINT is a valid nonzero value.
- If the z/OS Communications Server level is at V3R4.0, or PSDINT is 0 or defaulted with higher levels of z/OS Communications Server, DFHZSLS calls DFHZGSL to issue SETLOGON OPTCD=NPERSIST.
- If the z/OS Communications Server level is earlier than V3R4.0, the SETLOGON OPTCD call is not made because PERSIST and NPERSIST are not supported for these z/OS Communications Server releases.
- DFHSII1 attaches the III task which continues to run code in DFHSII1.
- DFHSII1 (III) attaches and calls DFHTCRP as a system task and then attaches task CGRP, which runs program DFHZCGRP which calls ZGRP.
- DFHZGRP calls DFHZGUB if there are any sessions to unbind.
- DFHZGRP queues any sessions to be restored to DFHZACT.
- DFHZGRP sets TCTV_RA_DONE after issuing RECEIVE_ANY commands to allow DFHZDSP to continue.
- DFHZGRP posts TCTV_ZGRP_FIN_ECB.
- When DFHZGRP finishes, control is returned to code in DFHZCGRP.
DFHZCGRP checks the RESPONSE and REASON code. It sets TCTV_ZGRP_FAILED off if RESPONSE(OK) or RESPONSE(EXCEPTION) with REASON(ACB_CLOSED|INQUIRE_FAILED). Otherwise, it sets TCTV_ZGRP_FAILED on.
- DFHSII1 waits on TCTV_ZGRP_FIN_ECB and checks if TCTV_ZGRP_FAILED
was set on by DFHSII1.
If TCTV_ZGRP_FAILED is off, DFHSII1 continues. Otherwise, it sets INITDERR, which causes CICS to stop when the other tasks have finished.
- Just before CONTROL IS GIVEN to CICS, DFHSIJ1 attaches the CXRE task to run DFHZXRE0, which does some additional PRSS processing.
- DFHZXRC or DFHZXPS are then called to process any TCTTEs queued to DFHZACT.
- DFHZXRC is called by DFHZACT to process non-APPC sessions that have not been unbound by DFHZGRP.
It takes one of the following actions depending on the state of the session, the terminal type, and
how the TYPETERM for the session has been defined to CICS:
- Send END_BRACKET.
- Send CLEAR (followed by START_DATA_TRAFFIC for SNA devices which support it).
- Unbind.
For those devices for which the clean up action is not to unbind, the TCTTE is queued to DFHZNAC and message DFHZC0146 is issued for the session.
As part of the processing for message DFHZC0146, any recovery notification requested for the session is initiated:- If the requested recovery notification is MESSAGE, DFHZNCA sends a BMS map to the terminal.
- If the requested recovery notification is TRANSACTION, DFHZNCA initiates the requested transaction.
- DFHZXPS is called by DFHZACT to process APPC sessions. DFHZXPS takes one of the following courses of action depending on the setting of TCTE_PRSS on entry.
- Examines the data pointed to by TCTV_PRSS_CV29_PTR to determine
the state of the session at system failure.
- If a task is attached, calls DFHZGDA to issue DEALLOCATE,ABEND for the task still running on the partner.
- If no task is attached but there is further recovery to be done, for example, bid recovery or outstanding responses, sets the TCTTE to a state which allows this further recovery to proceed. If the existing mechanism will carry out the recovery without further intervention by DFHZXPS, removes the TCTTE from the DFHZACT queue; otherwise, requeues the TCTTE to DFHZACT and DFHZXPS will be recalled at a later stage to finish recovery processing.
- If no task is attached and there is no further recovery to be done, removes the TCTTE from the DFHZACT queue because recovery is now complete.
- Recalls DFHZGDA to continue with DEALLOCATE,ABEND or REJECT_ATTACH processing.
- Requeues the TCTTE to DFHZACT if a SEND (for example, of an outstanding response), which was set in motion by an earlier instance of DFHZXPS, is still in progress.
- Issues CLSDST for the session if an error has occurred during the recovery process.
- Carries out further recovery as described earlier, if required, following successful completion of DEALLOCATE,ABEND processing.
- Removes the TCTTE from the DFHZACT queue when all recovery has completed.
- Examines the data pointed to by TCTV_PRSS_CV29_PTR to determine
the state of the session at system failure.