Using dynamic exits services

The CSVDYNEX macro provides exits and controls their use; it also provides a way for you to associate one or more exit routines with those exits. You might be familiar with system installation exits that offer your programs an opportunity to interrupt the system's processing for any number of good reasons; generally the reason is for the system to obtain information on which to base its processing. Often, however, programs or vendor products take advantage of an installation exit to do processing of their own. CSVDYNEX allows you to define exits and control their use just as the system does when it offers installation exits.

The dynamic exits facility is a set of services implemented by:
  • The EXIT statement of the PROGxx parmlib member. The EXIT statement allows an installation to add exit routines to an exit, delete an exit routine for an exit, change the state of an exit routine, change the attributes of an exit, and undefine an implicitly defined exit.

    The PROGxx EXIT statement interacts with the PROG=xx parameter of IEASYSxx and the SET PROG=xx command. At IPL, operators can use PROG=xx to specify the particular PROGxx parmlib member the system is to use. During normal processing, operators can use the SET PROG=xx command to set a current PROGxx parmlib member. See z/OS MVS Initialization and Tuning Reference for information about the PROGxx parmlib member.

  • The SETPROG EXIT operator command. This command performs the same functions as the EXIT statement of the PROGxx parmlib member. See z/OS MVS System Commands for information about the SETPROG EXIT command.
  • The CSVDYNEX macro.

An installation can use any of these methods to control dynamic exits. For example, an exit routine can be associated with an exit using the CSVDYNEX ADD request, the SETPROG EXIT,ADD operator command, or the EXIT statement of PROGxx.

Through the CSVDYNEX macro you can define an exit, control its use, and associate exit routines with it. None of these actions require a system IPL. The macro is of interest to two kinds of applications:
  • The application that wants to offer an opportunity for another program, an exit routine, to intercept the application's processing. This application, known as the exit provider, defines the exit and calls the exit routine or routines.
  • The application that wants one of its own routines to get control through an exit defined through CSVDYNEX. This application is known as the exit associator.

    CSVDYNEX, for example, allows you to associate one or more routines you are currently using, or plan to develop, with the existing SMF and allocation installation exits. Those exits have been defined to the dynamic exits facility.

The same application might be both exit provider and exit associator.