Temporary storage is the primary CICS® facility for storing data that must be available to multiple transactions. Data items that are in temporary storage are kept in queues whose names are assigned dynamically by the program that stores the data. You do not need to define temporary storage queues in the resource definitions. A temporary storage queue that contains multiple items can be thought of as a miniature file whose records can be addressed either sequentially, or directly by item number. If a queue contains only a single item, it can be thought of as a named scratchpad area.
Temporary storage is implemented in two different ways. Which one is used for a particular queue is determined by what is specified on the command that creates the first item. MAIN means that the queue is kept in memory, and AUXILIARY means that the queue is written to disk storage. For either method, CICS maintains an index of items in main storage.
Both these methods have characteristics that you should keep in mind:
Only one transaction at a time can update a recoverable temporary storage queue. If you choose to make queues recoverable, keep in mind the possibility of enqueues.
The following points apply to temporary storage in general: