GLI Recovery

The first record returned by GLI to an external program at BOJ (beginning-of-job) is the value OK, except where recovery is required.

Where, recovery is required, the first record passed back at BOJ is:

RECOVE number

Where, number is an eight-digit number indicating the number of GLI data records processed.

If input is from a file, the GLI program repositions the input file to the correct record for restarting. If input is from an external program using pipes, provision must be made to ensure that the correct number of records is supplied when recovery is required. The RECOVE message is a signal to the external program that it must resynchronize with the application.

If the system/FORMSGLI file is not present in the application directory on a GLI recovery run, the output passed by GLI to your user GLI program has the following format:

RECOVE number REQNUMBERS

This requests that the header records be resent to the GLI program. To run recovery, all records must be resent. The header records are processed, and the data records are rejected if they have been entered before. (Records that have been entered before are determined by maintaining a counter of records received from the GLI user program.)

To abort recovery and treat this as a new run with new data, the user GLI program must send the following back as its first input:

NORECO;

Notes:

  • GLI does not recognize whether records being sent have been previously processed.

  • GLI does not detect values of Glb.Spaces or Glb.Zeros declared for a key.

  • GLI produces a workfile named FORMGLI. This file is used by GLI Recovery, and is purged by GLI at normal EOJ.