Writing a CICS–DBCTL interface status program

The CICS®–DBCTL interface status program DFHDBUEX is a user-replaceable program forming part of the support for the CICS–DBCTL interface. It is designed to invoke user-supplied code whenever CICS successfully connects to or disconnects from DBCTL. It runs in a CICS application environment and is driven at specific points to allow you to enable and disable your CICS-DL/I transactions when the CICS–DBCTL interface initializes or terminates.

DFHDBUEX is called in the following case for the ENABLE command:
  • CICS has connected to DBCTL successfully. This occurs after a connection request has been issued from CICS to DBCTL. The control exit (DFHDBCTX) is invoked by the database resource adapter (DRA) for ‘initialization complete'. The control exit posts the control transaction (CDBO). The control program (DFHDBCT) then invokes DFHDBUEX.
DFHDBUEX is called in the following cases for the DISABLE command:
  • A request has been issued to disconnect from DBCTL. The CICS–DBCTL menu program (DFHDBME) starts the disconnection transaction (CDBT) to disconnect from DBCTL. The disconnection program (DFHDBDSC) invokes DFHDBUEX before issuing the interface termination request to the adapter.
  • The control transaction (CDBO) has been notified of one of the following events:
    • A checkpoint freeze request to DBCTL
    • DRA abnormal termination
    • DBCTL abnormal termination.
    In each of these cases, the control program (DFHDBCT) invokes DFHDBUEX.
Input to DFHDBUEX is by means of a communication area addressed by DFHEICAP. The layout of the communication area is shown in Figure 1.
Figure 1. The DFHDBUEX communication area
DBUSHEAD    DS      OCL4              Standard Header
DBUREQT     DS      CL1               Function Code
DBUCOMP     DS      CL2               Component Code         Always "DB"
DBURESV     DS      CL1               Reserved
DBUREAS     DS      CL1               Reason for disconnection
DBUSUFF     DS      CL2               DRA startup table suffix
DBUDBCTL    DS      CL4               DBCTL identifier
The parameter list contains the following information:
DBUREQT
Request Type. The function code has one of the following values:
DBUCONN (X'01')
Connected
DBUDISC (X'02')
Disconnected.
DBUREAS
Reason for Disconnection. Contains flags:
DBUMENU (X'01')
Disconnected from menu
DBUDBCC (X'02')
Checkpoint Freeze input to DBCTL
DBUDRAF (X'03')
DRA Failure has taken place
DBUDBCF (X'04')
DBCTL Failure has taken place.
DBUSUFF
DRA startup table suffix.
DBUDBCTL
DBCTL identifier.


dfha38k.html | Timestamp icon Last updated: Sunday, 4 June 2017