Waiting for Transfer Requests to Complete

When you run a REXX exec to queue a request to the platform server address space, the request typically ends when the request is successfully queued. If you want to wait for the completion of the request, you can specify the platform server wait parameters.

The platform server supports two types of wait parameters:

  • MWAIT: adds the request to a list of requests to be waited on and returns control to the platform server REXX exec. When you are ready to wait for all of the requests on the list to complete, issue the FUSWAIT exec.

    For more information of this parameter, see Waiting for Multiple Requests to Complete.

    For more information of the FUSWAIT exec, see FUSWAIT.

    Note: You can use the FUSWCLR exec to clear out all requests on the MWAIT list. For more information of the FUSWCLR, see FUSWCLR.
  • WAIT: waits and returns to the platform server REXX exec until the request is completed, either successfully or unsuccessfully.

    For more information of this parameter, see Waiting for a Single Request to Complete.

For best results, when you use the WAIT parameter, set the retry count to the default value of 1. In such cases, the request might not be inactive for a long period of time waiting for a retry. It is good practice to use the default values of the DATE and TIME parameters so that the request is executed immediately.

The following table lists the parameters that can be specified on a WAIT request, or on the FUSWAIT REXX exec:

Parameter Description
INTERVAL={number_of_seconds | 10} Defines the number of seconds that the platform server REXX exec waits between status checks of the requests.

The platform server REXX exec inquires on the transaction until it is completed successfully or unsuccessfully. After every check, the REXX exec waits the number of seconds defined in the INTERVAL parameter.

The valid values are 1 - 9999 and the default value is 10.

Note: If you do not specify this parameter, the default value is used. Setting this value too low can cause excessive checks on the request, while setting it too high can cause excessive waits between checks.
TIMEOUT={number_of_seconds | 300} Defines how long the REXX exec continues to check the status of the requests.

When the time you defined in this parameter expires, the platform server stops scanning for the request status. Based on the PURGE parameter, the platform server either purges all requests that are still on the queue, or returns directly without purging any requests.

The valid values are 1 - 9999 and the default value is 300.

Note: If you do not specify this parameter, the default value is used.
PURGE Defines the platform server to purge all requests that are not completed on the queue when the timeout interval expires.
Note: If this parameter is not specified, the platform server takes no action on the uncompleted requests when the timeout interval expires.
SAY Defines the platform server REXX exec to write a status record each time after the platform server checks the status of a transfer.

The status record includes the transaction number, the current status, and the current record and byte counts.

Note: If this parameter is not specified, the status record is not displayed. If this parameter is specified for a TSO user, the record is sent to the terminal. If this parameter is specified on a batch mode, the record is sent to the DD statement, SYSTSPRT.