Writing to the log dataset

Business Continuity Manager Web API Reference Guide

Version
9.9.1
Audience
anonymous
Part Number
MK-96HC137-03

Writing to the log dataset

If both of the two log record datasets, BCM-Web-API-log-dataset-prefix.LOG1 and BCM-Web-API-log-dataset-prefix.LOG2, are allocated, log data is written as follows:

  1. The number (1 or 2) of the log to which data was last written is recorded in a record of BCM-Web-API-log-dataset-prefix.LOG0 (the log control dataset). New log data is written to the log corresponding to that number.

    If the log control dataset has no record, log data is written from the beginning of BCM-Web-API-log-dataset-prefix.LOG1.

  2. When the log record dataset is full, log data is written from the beginning of the other log record dataset.
  3. Steps 1 and 2 are repeated.

If one of the log record datasets has not been allocated, a message is output and log data is output to only the dataset that has been allocated. When the dataset becomes full, it is overwritten from the beginning.

If any of the following conditions is met, a message is output, log data is not collected, and processing continues.

  • Neither of the BCM Web API log record datasets have been allocated.
  • The BCM Web API log control dataset has not been allocated.
  • For the default parameter dataset, the APILOGPREFIX parameter is not specified.

To output log data after allocating the log datasets or specifying the APILOGPREFIX parameter, you need to restart the BCM Web API server.

If an I/O error occurs in a log record dataset, a message is output and log data is output to only the log dataset where no I/O error has occurred. In such cases, when the log record dataset becomes full, it is overwritten from the beginning. If an I/O error occurs in both log record datasets, log data is not collected and processing continues.

Timing for opening and closing a log dataset

The log record datasets are allocated to the DD name YKAPIL01.

The log record datasets are allocated to the DD name, opened, output, and closed after a response is sent or when the BCM Web API server ends.

Timing for opening and closing the log control dataset

The log control dataset is allocated to the DD name YKAPIL00.

The log control dataset is allocated, opened, input, and closed before the log record datasets are allocated. In addition, the log control dataset is released after the log record datasets are output.

The log control dataset is opened, output, and closed when the log record datasets are full.