Commit notify object

 

A notify object is a message queue, data area, or database file that contains information identifying the last successful transaction completed for a particular commitment definition if that commitment definition did not end normally.

The information used to identify the last successful transaction for a commitment definition is given by the commit identification that associates a commit operation with a specific set of committable resource changes.

The commit identification of the last successful transaction for a commitment definition is placed in the notify object only if the commitment definition does not end normally. This information can be used to help determine where processing for an application ended so that the application can be started again.

For independent disk pools, the notify object must reside on the same independent disk pool or independent disk pool group as the commitment definition. If you move the commitment definition to another independent disk pool or independent disk pool group, the notify object must also reside on that other independent disk pool or independent disk pool group. The notify object on the other independent disk pool or independent disk pool group is updated if the commitment definition ends abnormally. If the notify object is not found on the other independent disk pool or independent disk pool group, the update fails with message CPF8358.

If journaled resources participate in the current transaction and a commit operation is performed with a commit identification, the commit identification is placed in the commit journal entry (journal code and entry type of C CM) that identifies that particular transaction as being committed. A commit journal entry containing the commit identification is sent to each journal associated with resources that participated in the transaction.

The following table shows how you specify the commit identification and its maximum size. If the commit identification exceeds its maximum size, it is truncated when it is written to the notify object.

Language Operation Maximum characters in commit identification
CL COMMIT command 3000 1
Integrated Language Environment® (ILE) RPG COMIT operation code 4000 1
PLI PLICOMMIT subroutine 4000 1
ILE C _Rcommit function 4000 1
ILE COBOL COMMIT verb Not supported
SQL COMMIT statement Not supported

1If the notify object is a data area, the maximum size is 2000 characters.

When a notify object is updated with the commit identification, it is updated as follows:

Database file

If a database file is used as the notify object, the commit identification is added to the end of the file. Any existing records will be left in the file. Because several users or jobs can be changing records at the same time, each commit identification in the file contains unique information to associate the data with the job and commitment definition that failed. The file that serves can be journaled

Data area

If a data area is used as the notify object, the entire content of the data area is replaced when the commit identification is placed in the data area. If more than one user or job is using the same program, only the commit identification from the last commitment definition that did not end normally will be in the data area. Consequently, a single data area notify object might not produce the correct information for starting the application programs again. To solve this problem, use a separate data area for each commitment definition for each workstation user or job.

Message queue

If a message queue is used as a notify object, message CPI8399 is sent to the message queue. The commit identification is placed in the second-level text for message CPI8399. As with using a database file for the notify object, the contents of each commit identification uniquely identify a particular commitment definition for a job so that an application program can be started again.

 

Parent topic:

Starting commitment control

Related concepts
Commitment control for batch applications Example: Using a notify object to start an application