Canceling user activity

When users reach their resource limits, you can call the QMF cancellation service to cancel user activity. For example, your governor exit routine might cancel the following:

The code for canceling either of the first two activities is contained in the source program DSQUnGV1, DSQUnGV2, or DSQUnGV3. To have your governor call the QMF cancelation service to cancel an activity, branch to the address that appears in the DXEGOVA control block field named GOVCADDR. Figure 245 shows the statements that establish addressability to the QMF cancellation service. Before you use these statements to pass control from the governor exit routine to QMF, ensure that Register 13 points to a save area for the governor so that QMF can restore the state of the governor upon returning control.

Figure 245. Calling the QMF cancellation service
L R15,GOVCADDR
         BALR R14,R15

The cancellation routine returns control to the point addressed by Register 14 (in this case, the command that follows the BALR command). Register 15 contains a return code of 0 if QMF accepted the request to cancel, and a return code of 100 if the governor requested a cancel when QMF was inactive.

To cancel QMF commands using asynchronous processing in TSO, native OS/390, or CMS, the IBM-supplied governor uses a timer macro, which returns control to a timer routine. The timer routine tests whether to cancel the current command. If the command is to be canceled, it carries out the cancellation. The tests are based on processor time (TSO and native OS/390) or real time (CMS), and the number of rows fetched for the current DATA object. Your VM system should be running with the value of CP TIMER set to REAL. The tests can also be based on the user's response to a cancellation prompt.

The timer routine is the CSECT named TIMEX in the source code for the IBM-supplied governor. On OS/390 the source code is the member DSQUnGV1 of the library QMF720.SDSQUSRE. On CMS the source code is the file DSQUnGV2 on the production disk.

Making an asynchronous cancellation call is very much like pressing PA1. Cancellation might not be immediate, and it might be impossible. Before the cancellation takes place, control can return to the governor.

[ Previous Page | Next Page | Contents | Index ]