Threadsafe restrictions
An open API TRUE must not treat the executing openTCB environment in such a
way that it causes problems for:
vOther open API TRUEs called by the same task
vOPENAPI programs called by the same task
vApplication program logic that could run on the open TCB
vFuture tasks that might use the open TCB
vCICS management code.
In particular:
vWhen invoking CICS services, or when returning to CICS, an open API TRUE
must ensure it restores the MVS programming environment as it was on entry to
the TRUE. This includes cross-memory mode,ASC mode, request block (RB)
level, linkage stack level, TCB dispatching priority,in addition to cancelling any
ESTAEs added.
vAt CICS task termination, an open API TRUE must ensure it leaves the open
TCB in a state suitable to be reused by another CICS transaction. In particular, it
must ensure that all non-CICS resources acquired specifically on behalf of the
terminating task are freed. Such resources might include:
Dynamically allocated data sets
Open ACBs or DCBs
STIMERM requests
MVS managed storage
ENQ requests
Attached subtasks
Loaded modules
Owned data spaces
Added access list entries
Name/token pairs
Fixed pages
Security settings (TCBSENV must be set to zero)
vAn open API TRUE must not use the following MVS system services that will
affect overall CICS operation:
– CHKPT
– ESPIE
– QEDIT
– SPIE
– STIMER
– TTIMER
XCTL / XCTLX
Any TSO/E services.
vAn open API TRUE must not invoke under the L8 modeTCB a Language
Environment program that is using MVS Language Environment services,
because L8 mode TCBs are initialized for Language Environment using CICS
services.
Calling an OPENAPI task-related user exit
If a task-related user exit is enabled with the OPENAPI option, CICS uses the
following rules, based on the type of call, to determine the TCB on which it should
invoke the TRUE—on the QR TCB, on the caller's TCB, or an L8 mode TCB:
272 Customization Guide