Synchronous and asynchronous processing

Depending on the operating environment, an event control block (ECB) can be resident in one of two places: the home address space (in private storage) or in common storage.

Use the MODE parameter on the IXGWRITE, IXGBRWSE, and IXGDELET services to choose one of the following:
  • MODE=SYNC
  • MODE=SYNCECB
  • MODE=SYNCEXIT
  • MODE=ASYNCNORESPONSE
The following conditions shows where the ECB might appear in an environment that includes a caller address space, a server address space, and the system logger address space. In these conditions, the server provides services to the caller.
  • Choosing MODE=SYNC

    Choose MODE=SYNC to specify that the request be processed synchronously. When control returns to the caller, all processing on behalf of the request is complete.

  • Choosing MODE=SYNCECB

    Choose MODE=SYNCECB to specify that the request be processed synchronously, if possible. If the system logger request cannot be completed synchronously, processing on behalf of the request might still be in progress when control returns to the caller (see MODE=ASYNCNORESPONSE). When the asynchronous processing for the request completes, the ECB specified on the system logger request is posted. Once the ECB is posted, the caller can examine the answer area to verify whether the request completed successfully.

  • Choosing MODE=ASYNCNORESPONSE

    Choose MODE=ASYNCNORESPONSE on the IXGWRITE and IXGDELET requests to specify that the request be processed asynchronously. The caller will not be informed when the request completes. The answer area returned in the ANSAREA parameter and mapped by IXGANSAA is not valid when you specify MODE=ASYNCNORESPONSE.

When a system logger request cannot be completed synchronously, system logger indicates this by returning to the invoking program with a specific return code X'4' and reason code X'401' (IxgRetCodeWarning and IxgRsnCodeProcessedAsynch, re: macro IXGCON).

Before system logger returns control to the caller it schedules an SRB to complete processing of the request. While the SRB runs independent of the requesting task, the SRB might encounter an error from which it cannot recover. The SRB ensures that the error condition is percolated to the task that issued the system logger request.

Note: Depending on the exploiter's structure, this task might not be the same task that originally issued the IXGCONN request to connect to a log stream.
Prior to percolating the error to the requesting task, system logger issues the SETRP macro, specifying SERIAL=YES. System logger also places additional diagnostic information in the SDWA, as follows:
SDWACMPC
The completion code, set to X'1C5'.
SDWACRC
The reason code, set to X'85F'.
SDWACOMU
The ECB address specified on the ECB keyword when system logger was invoked.

If the caller receives a return code indicating that system logger will process the request asynchronously, the application cannot free certain storage areas.

Reference information: See z/OS MVS Programming: Assembler Services Reference IAR-XCT for the specific service's return code.