Application threads
When the application program issues its first call for data resources owned by an external subsystem, a thread is created to connect the application to the external subsystem.
IMS activates a Create Thread exit routine supplied in the ESAP to identify the application program to the external subsystem. The external subsystem is expected to prepare to receive data requests from the specific application program as necessary (that is, reserve resources, create a processing structure, and so on). When the application terminates, IMS activates a Terminate Thread exit routine to terminate the thread.