10. MODIFICATION › 10.2 User Exits › 10.2.1 Input Exits
10.2.1 Input Exits
This section provides a description of the input exit that is
shared by CICS with the other installed CA MICS components.
The exit description includes the name and title, a
description of its purpose, when it is invoked, and whether
it has an interface to the CA MICS Accounting and Chargeback
Option. It also shows which data elements are available, the
special considerations to note, and a sample user exit.
+-------------+
| U S R S E L | Input Record Selection Exit (USRSEL)
+-------------+
DESCRIPTION: The _USRSEL exit lets you prevent records from
being processed by the CA MICS Analyzer Option for CICS. It
is similarly invoked in input format routines for other CA
MICS components. It can be defined at the complex level in
sharedprefix.MICS.SOURCE(#BASEXIT) or at the unit level in
prefix.MICS.USER.SOURCE(#BASEXIT).
INVOCATION: For the CA MICS Analyzer Option for CICS, the
_USRSEL exit gains control during the input format routine.
It is invoked for each input record processed from CMF and
ASG-TMON. Note that each CMF physical record can contain
multiple logical transaction records. The _USRSEL exit is
invoked once per CMF physical record.
ACCOUNTING INTERFACE: No interface is provided.
USES: This exit can be used to exclude records from being
processed by the CA MICS Analyzer Option for CICS during the
daily input step. To exclude a record, set SKIP_REC to one.
For example, you can code the following to skip records that
contain the SMF system ID TEST:
MACRO _USRSEL;
IF ROUTINE EQ 'DYCICFMT' THEN DO;
IF ORGSYSID EQ 'TEST' THEN SKIP_REC=1;
END;
%
The CA MICS Analyzer Option for CICS provides the appropriate
logic to delete the record based on the value of SKIP-REC
after the _USRSEL exit is invoked.
ELEMENTS AVAILABLE: ORGSYSID - Original System ID
CODING RESTRICTIONS: Do not refer to any CA MICS-assigned
data elements, such as CICSID and CICACTx, when setting
SKIP_REC in this exit. Extra records will be deleted as a
result. For additional coding restrictions, see section
4.2.5 of the System Modification Guide.
+---------------+
| U S R S C I D | Input Record Set CICSID Exit (USRSCID)
+---------------+
DESCRIPTION: The %USRSCID exit lets you set the CICSID when
a record's ORGSYSID/APPLID has not been defined in CICOPS.
Normally, a record whose ORGSYSID/APPLID has not been defined
will be discarded, and message CIC06011E will be written to
the MICSLOG. By implementing the USRSCID exit, you can set
the 4-byte CICSID and the record will be processed. The
CICSID value supplied by the exit, in combination with the
ORGSYSID, must be unique.
The daily update run will be terminated, and a MICSLOG error
message will be issued if the USRSCID exit code generates a
CICSID value that:
- Duplicates a ORGSYSID/CICSID combination already
specified in CICOPS with a CICOPTS statement.
Error Message - CIC06173E
- Duplicates a ORGSYSID/CICSID already generated by this
exit for a different APPLID.
Error Message - CIC06173E
- Duplicates a CICS Transaction Gateway CTGID specified in
CICOPS with a GATEWAY APPLID statement.
Error Message - CIC07085E
The intent of this exit is to avoid discarding data for new
CICS regions that were not yet defined in CICOPS. Due to
additional overhead incurred in the assignment of CICSIDs
through the use of this exit, it is strongly recommended that
you update CICOPS and run a CICPGEN subsequent to any DAILY
run that encounters data that is not defined in CICOPS. When
undefined data is encountered and this exit is used to assign
the CICSID, message CIC06174W will be issued, with the last
line providing a sample CICOPTS statement:
CIC06174 USER EXIT USRSCID PROVIDED CICSID=%CICSID
CIC06174 FOR ORGSYSID=%ORGSYSID, APPLID=%CSUAPPL
CIC06174 PLEASE UPDATE CICOPS ACCORDINGLY
CIC06174 AND RUN CICPGEN BEFORE NEXT DAILY RUN
CIC06174 ...SAMPLE CICOPTS, BE SURE TO SET SELCODE...
CIC06174 CICOPTS %ORGSYSID %CICSID SMF CMF 0 %CSUAPPL ??
INVOCATION: The %USRSCID exit is passed control only when
a record is encountered that does not find a matching
ORGSYSID/APPLID in CICOPS.
ACCOUNTING INTERFACE: No interface is provided.
USES: This exit can be used to process records whose
ORGSYSID/APPLID has not been defined in CICOPS. Normally,
a subset of CSUAPPL would be used to set CICSID. For
example:
%MACRO USRSCID;
CICSID = SUBSTR(CSUAPPL,5,4) /* set CICSID to last 4 chars*/
%MEND USRSCID;
ELEMENTS AVAILABLE: ORGSYSID - Original System ID
CSUAPPL - Original APPLID
CICSID - CICS ID
SELCODE - Select Code
CODING RESTRICTIONS: The value assigned to CICSID by the
exit for a given ORGSYSID must be unique. If the
ORGSYSID/CICSID combination was previously defined in CICOPS,
or by the exit for a different APPLID, the run is terminated.
The value assigned to CICSID must contain only alphanumeric
characters or a dash (-), with a length of 1 to 4 bytes.
CICSID is initialized to blanks prior to invocation of the
exit. If CICSID contains blanks upon return from the exit,
CIC06011E will be issued.
It is also necessary to set SELCODE if other than the default
value of 0 (zero) is required. For valid SELCODE values, see
section 7.3.2, CICS Processing Options (CICOPS).
For additional coding restrictions, see section 4.2.5 of the
System Modification Guide.
+----------------+
| U S R S K I P | User Data Skip Exit
+----------------+
DESCRIPTION: The USRSKIP exit enables you to skip CMF
records during DAY040 processing. The exit is invoked
immediately after reading the SMF record header. You may use
the exit to determine whether or not the physical record,
which may contain multiple CICS transaction records, should
be excluded from input processing. This exit can also be
used to change the value of ORGSYSID if so desired.
INVOCATION: The USRSKIP exit is invoked immediately after
reading the SMF record header for CMF input.
ACCOUNTING INTERFACE: No interface is provided.
USES: Use this exit to exclude data from DAY040 input
processing or to change the value of ORGSYSID.
ELEMENTS AVAILABLE: Temporary variables including SMFRTYP
(SMF record type), SMFTIME (SMF record end timestamp),
ORGSYSID (SMF system ID), SMFLPS (SMF section header length),
and INPRECS (Physical input record number).
CODING RESTRICTIONS: Set SKIP_REC to 1 to exclude records
from DAY040 processing. The following example shows how to
change the value of ORGSYSID, as well as reject a record
based on the value of ORGSYSID:
%MACRO USRSKIP;
IF ORGSYSID EQ 'TSTX' THEN ORGSYSID EQ 'TSTA';
ELSE IF ORGSYSID EQ 'TSTG' THEN SKIP_REC=1;
%MEND USRSKIP;