Recording from CICS

Recording under CICS is activated by using either a CICS transaction or a web service call, which then installs several CICS global exits.

The global exits are active for all users and applications that run within CICS, whether the user started the recording or not. Any individual can start the recording and they are isolated from other active users. All data is intercepted once the exits have been started, but it is filtered out based on a set of criteria that is defined by the user. All data that passes the criteria is then saved into an interim VSAM file. To differentiate the records for a specific user, interfaces have been provided.

The following list is the process.
  • Start the recording for a terminal using a transaction (BZUS), for a transaction using a transaction (BZUT), or a web service call through IBM® Developer for z/OS®.
  • Any number of users will run as few or as many transactions as wanted.
  • Stop the recording by using a transaction (BZUE) or a web service call through IBM Developer for z/OS.
  • Extract the wanted data from the interim VSAM file and write to transient data by using a transaction (BZUW) or a web service call through IBM Developer for z/OS.

The process can be started and stopped as many times as needed. Any number of transactions can be recorded and saved during the process. Any number of these saved transactions can be replayed later. This permits a user to replay the automated testing on as few as one transaction for a single test, to as many transactions as are wanted comprising a complete system test.

When the process is started for the first time, or restarted after all users have stopped recording, then the configuration file will be reread and processed, if one exists. This allows a user to alter the configuration options or the list of programs to be intercepted without having to recycle CICS.

At some point, the user requests that their interim recorded data is written to an external file through a CICS transient data queue. Whether the default queue (BZUQ) or a user-define queue is used, it is important to understand how the CICS CSD definition for the queue works. The queue can be defined in the CICS CSD definition as OLD, SHR, or MOD. The use of OLD or SHR will causes the external data set to be replaced, whereas the use of MOD causes it to be appended.

Recording can be managed by using these previously described transactions or through IBM Developer for z/OS which manages through the web service interface. The processes are compatible, and the resulting recorded data is identical.

Over time the interim VSAM file can get cluttered with old data. Whenever an extraction is done, the extracted records are removed from the VSAM file, however records from other users might have been recorded and never extracted. Reinitializing the interim VSAM file from time to time is helpful.