Data flow in request processing
To make decisions about the facilities you will use, and how you will customize them, you need to understand how data is passed in the CICS® business logic interface.
What converter programs perform in request processing
You can have many converter programs in a CICS system to support the operation of the CICS business logic interface.
The place of converters in the CICS business logic interface is illustrated in Figure 1 and Figure 2. Each
converter must provide two functions, decode and encode.
- Decode
- Decode is used before the CICS application program is called. It can:
- Use the data from the incoming request to build the COMMAREA in the format expected by the application program.
- Supply the lengths of the input and output data in the application program's COMMAREA.
- Perform administrative tasks related to the request.
- Encode
- Encode is used after the CICS application program has been called. It can:
- Use the data from the application program to build the response.
- Perform administrative tasks related to the response.
Notes:
- If DECODE_DATA_PTR or ENCODE_DATA_PTR has been altered to address another storage location, it is the converter program's responsibility to freemain the original storage.
- It is the responsibility of the caller of the CICS business logic interface to free the buffer addressed by ENCODE_DATA_PTR (that is, the address returned in field WBBL_OUTDATA_PTR minus 4).
- If the converter abends, CICS will attempt to free the storage addressed by DECODE_DATA_PTR and ENCODE_DATA_PTR. Therefore, you should ensure that these pointers never contain the address of storage that has already been freed.