DEFINE PROCESS
Define a CICS® (BTS) Business Transaction Services process.
Syntax
Conditions: INVREQ, IOERR, NOTAUTH, PROCESSERR, TRANSIDERR
NOHANDLE, RESP, and
RESP2 are common options that can be added to all EXEC CICS
commands to process error conditions. They are not explicitly included in the command syntax diagram
and option descriptions. For information about these common options and EXEC CICS
command syntax, see EXEC CICS command format and programming considerations.
Description
DEFINE PROCESS defines a BTS process. It adds a new process (for example, a new instance of a business transaction) to the CICS business transaction services system and creates the process's root activity.
The name of the program that is used in the execution of the new process is taken either from the PROGRAM option, or, if PROGRAM is not specified, from the transaction definition pointed to by the TRANSID option.
The transaction attributes specified on the TRANSID and USERID options take effect when the process is activated by a RUN command, but not if it is activated by a LINK command—see RUN.
BTS does not commit the addition of the process until the requesting transaction has taken a successful syncpoint.
Options
- NOCHECK
- Specifies that
no record is to be written to the repository data set to reserve the name of the process.
Note that the process name must be unique in the repository—see the PROCESS and PROCESSTYPE options—and that BTS does not commit the addition of the process until the requesting transaction has taken a successful syncpoint.
You can use this option to improve BTS performance by removing the write to the repository and its associated logging. However, be aware that the error of specifying a non-unique process name does not cause a PROCESSERR condition to be returned on the DEFINE PROCESS command. The error might not be discovered until much later—when syncpoint occurs— which makes it harder to debug.
- PROCESS(data-value)
- Specifies a
name (1–36 characters) to identify the new process (business transaction instance). The name
must be unique within the BTS repository data set on which details of the process are to be stored
(see the PROCESSTYPE option). For example, it is valid to issue a DEFINE command where the PROCESS
option specifies a name that is currently in use by another process, if the PROCESSTYPE
option maps to a different underlying repository data set from that on which the first process is
defined.
Acceptable characters are A-Z a-z 0-9 $ @ # / % & ? ! : | " = ¬ , ; < > . - and _. Leading and embedded blank characters are also permitted.
If the name is specified as a literal string that is fewer than 36 characters long, it is padded with trailing blanks up to 36 characters. If the name is specified as a variable whose value is fewer than 36 characters long, no padding occurs.
- PROCESSTYPE(data-value)
- Specifies
the type (1–8 characters) of the new process.
Each process-type maps to a VSAM data set (the repository), on which information about processes of the named type is stored. That is, information about the state of a process (and of its constituent activities) is stored on the repository that is associated with the process-type to which it belongs. Records for multiple process-types can be stored on the same repository data set.
You can categorize your processes by assigning them to different process-types.
- PROGRAM(data-value)
- Specifies the name (1–8 characters) of the program for the process being added. If no program is specified, the name is taken from the TRANSID definition.
- TRANSID(data-value)
- Specifies the
name (1–4 characters) of the transaction under which the process is to run when it is
activated by a RUN command. If the process is activated by a LINK command, it is run under the
TRANSID of the transaction that issues the LINK.
The transaction must be defined in the CICS region in which the DEFINE PROCESS command is run.
- USERID(data-value)
- Specifies the user ID (1–8 characters) under whose authority the process runs when it is activated by a RUN command. If the process is activated by a LINK command, it runs under the user ID of the transaction that issues the LINK. Think® of this user ID as userid1.
If you omit USERID, the user ID that is used is the user ID under which the transaction that issues the DEFINE command runs. Think of this as userid2.
If USERID is specified, CICS performs (at define time) a surrogate security check to verify that the userid2 is authorized to act as userid1. If userid2 is not authorized, CICS returns a NOTAUTH condition. See Surrogate security.
Conditions
- 16 INVREQ
- RESP2
values:
- 12
- The installed PROCESSTYPE is not enabled.
- 22
- The unit of work that issued the DEFINE PROCESS command already acquired an activity.
- 17 IOERR
- RESP2
values:
- 29
- The repository file is unavailable.
- 30
- An input/output error occurred on the repository file.
- 70 NOTAUTH
- RESP2
values:
- 101
- The user that is associated with the issuing task is not authorized to access the file that is associated with the BTS repository data set on which details of the process are to be stored.
- 102
- The user that is associated with the issuing task is not authorized as a surrogate of the user ID that is specified on the USERID option.
- 108 PROCESSERR
- RESP2
values:
- 2
- The process name that is specified on the PROCESS option is already in use on the BTS repository data set that is associated with the PROCESSTYPE option.
- 9
- The process-type that is specified on the PROCESSTYPE option could not be found.
- 16
- The process name that is specified on the PROCESS option contains an invalid character or characters.
- 28 TRANSIDERR
- The transaction identifier that is specified on the TRANSID option is not defined to CICS.
