Timing the Archive
The archive must complete before IBM® Connect:Direct® needs to reuse the file being archived, that is, at the time of wrap-around of the file pair list. The completion of the archiving Process is important because IBM Connect:Direct erases the contents of the statistics file when the system switches to that file. In other words, archiving must complete within the time required for the file pair list to wrap. Normally, this condition does not present a problem.
Require Confirmation of Archival
The STAT.ARCH.CONFIRM initialization parameter specifies whether or not to ensure that data is archived before the system erases the file. If you do not want archiving, IBM Connect:Direct simply resets the files when the switching occurs, and begins writing. If you want archiving, IBM Connect:Direct verifies that the archive is complete before proceeding. In this case, IBM Connect:Direct requires notification of archival. IBM Connect:Direct is notified in several ways:
- If the archive is done using the COPY statement in a IBM Connect:Direct Process, then the Process can also invoke the DGADARRT utility when the COPY successfully completes. IBM Connect:Direct invokes DGADARRT through a RUN TASK statement, and notifies IBM Connect:Direct that the data is archived.
- If you use a batch job to archive, then the job can send the notification by including a step to execute the DGADARBT utility.
- Also, you can issue the API command STATISTICS ARCHIVED to inform IBM Connect:Direct to reuse a file pair.
If no indication regarding the completion of the archive exists when IBM Connect:Direct needs to reuse the files, the system issues a message, similar to the example shown below, to the operator console and waits for a reply indicating permission to reuse the file.
In this situation, all activity in the DTF ceases until a response to the message from the operator exists indicating that the statistics file can now be overwritten. This safeguard occurs as a result of the request that the DTF not erase statistics data unless it is certain that archiving the statistics is complete.
If you have not been requiring archival notification and decide to begin requiring it, you can avoid getting these messages by using the IUI command STAT, CF option and forcing all pairs not in use to indicate they have been archived.
Not Requiring Confirmation of Archival
IBM Connect:Direct does not require archive confirmation before reusing a statistics file pair when you specify or default to the DTF initialization parameter, STAT.ARCH.CONFIRM=NO. If you specify this initialization parameter, you are responsible for ensuring that the archive successfully completes before IBM Connect:Direct resets the file. If the file is reset before copying the records, the data is lost.
If the records are in the process of being copied when IBM Connect:Direct needs to reset the file, then IBM Connect:Direct must wait for the copy to complete. This operation is because IBM Connect:Direct must have exclusive access to the file to do the VSAM reset. In this situation, IBM Connect:Direct also issues a message to the operator console and waits for a reply indicating that the file can be reset.