Figure 1 is
a very simplified illustration of how
routines in a recovery environment interact. In this figure, only
one recovery routine exists, and it is an ESTAE-type recovery routine.
The following sequence of events might occur:
- The mainline
routine encounters an error.
- The system gets control.
- The
system looks for recovery routines and finds an ESTAE-type
recovery routine called ESTAEX.
- The ESTAEX routine either
retries or percolates.
- If the ESTAEX routine retries, it returns
control to a retry point
in the mainline routine. The mainline routine continues processing.
- If the ESTAEX routine percolates, the system gets control and
abnormally ends the mainline routine; then the system gives control
to any resource managers that are present.
Figure 1. Mainline
Routine with One Recovery Routine
Figure 2 shows
a more complex situation. Several
recovery routines exist, and each one that is entered has the opportunity
to retry or to percolate. The following sequence of events might
occur if all recovery routines percolate:
- The mainline routine
encounters an error.
- The system looks for recovery routines
and finds that the latest
FRR created is FRR(3).
- The system gives control to FRR(3)
first.
- FRR(3) percolates to FRR(2), which percolates to FRR(1).
- FRR(1) also percolates, so the system looks for ESTAE-type recovery
routines, and finds that ESTAEX(4) was the last one created.
- The
system gives control to ESTAEX(4) first.
- ESTAEX(4) percolates
to ARR(3), which percolates to ESTAE(2),
which percolates to ESTAI(1).
- ESTAI(1) also percolates, and
no other recovery routines are activated,
so the system abnormally ends the mainline routine, and passes control
to any resource managers that are present.
Had any
of the recovery routines decided to retry, the system would
have returned control to the retry point, and the mainline routine
might have ended normally.
Figure 2. Mainline
Routine with Several Recovery Routines