JECL services for BMC AMI Ops Automation for Batch ThruPut
This section introduces the JECL functions available with BMC ThruPut Manager.
Introduction
With the exception of the JECL statements provided for tracing (/*TM TRACE, /*JAL TRACE, and /*DAL TRACE), this section is primarily of interest to BMC ThruPut Manager installations with Job Binding Services (JBS), Dataset Contention Services (DCS), User Control Services (UCS) Drive Booking Services (DBS), or Service Level Manager (SLM).
In order to take advantage of the services offered by JBS, users need a way to indicate to BMC ThruPut Manager how individual jobs are to be managed. For example, jobs that require Binding Services must be able to specify which Binding Agent is requested. This and other job-related requests for JBS services are specified through the use of BMC ThruPut Manager JECL statements.
The BMC ThruPut Manager JES2 control statements follow JES2 conventions in terms of placement in the job stream and system processing. Their parsing, error messages and other system actions are all handled by BMC ThruPut Manager.
Considerations
The JECL control statements provided are unique to BMC ThruPut Manager; therefore, they are not recognized in a system without BMC ThruPut Manager, and will result in errors that terminate the offending job. This could present you with problems in some situations. For example, if you are evaluating BMC ThruPut Manager in a MAS complex you might install the product in only one machine. If you do not exercise tight control of your testing jobs, they could be read on one of the machines without BMC ThruPut Manager. If this happens, they will be failed by JES2.
Another situation occurs when you use Binding Agents to control transmission of jobs to another node. If the receiving NJE node does not have BMC ThruPut Manager installed, the JECL statements will cause errors.
Provisions have been made to handle the above situations. The identification software for BMC ThruPut Manager JECL statements allows for:
- Standard JES2 JECL, where statements begin with ‘/*’. Note that this format for JBS JECL statements is processed regardless of placement within the job.
- Unique identification, where statements begin with //*+. In a system without BMC ThruPut Manager, the statement is treated as a comment. This identification allows you to include BMC ThruPut Manager JECL statements in procedures for batch jobs, as discussed further below.
By default, only BMC ThruPut Manager JECL statements are supported. Other JECL statements using this form are rejected and the job fails with a JCL error; however, you can use the JECL keyword of the TMPARM statement to include user-defined JECL statements, as described later.
Exempt Classes and JECL Statements
Jobs submitted in Exempt classes are normally not processed by BMC ThruPut Manager unless the job has JECL statements that are recognized by BMC ThruPut Manager. In this case, the job is analyzed. If you want to ignore jobs that contain BMC ThruPut Manager JECL but are submitted in Exempt classes, you can code the JECLEXEMPT keyword on the TMPARM statement. Refer to the Installation Guide Section 3. TMPARM Initialization Statements.
) At JAL execution time you can detect when jobs submitted in Exempt classes are being analyzed because of JECL statements by testing the Job Descriptor $EXEMPT.
) If DCS is installed, even jobs in Exempt classes are managed for data set contention.
) JECL processed by the XLATE/JES2XLATE capability of the JECL keyword of the TMPARM JES2 initialization statement continues to be translated.
Capturing User JECL Statements
If your installation already has user JECL statements for functions similar to the ones offered by BMC ThruPut Manager, you can make the conversion, if not transparent, at least translucent, by using the JECL capture/conversion facility of BMC ThruPut Manager. Two related facilities are provided for this purpose:
- An automatic mapping mechanism.
- A User Exit.
BMC ThruPut Manager JECL statements are “captured” by the Job Selector at JES2 READER time. They are kept with the job and processed by BMC ThruPut Manager at Job Analysis time.
Automatic User JECL Mapping
A facility is provided that allows the definition of mappings of JECL statements. It also allows you to specify the actions to be taken by JES2 and BMC ThruPut Manager.
The definition is part of the TMPARM statement. The keyword is JECL. A brief description is provided below. For complete syntax details, refer to the Installation Guide Section 3. TMPARM Initialization Statements.
This keyword allows you to define the way you want BMC ThruPut Manager to handle named user-defined JECL statements. You can code as many repetitions of this keyword as necessary to map all of your user JECL statements.
Represents the first verb to be found in the user JECL statement. For example, for a JECL statement /*RESOURCE, verb1 is RESOURCE.
An optional second verb to handle compound JECL names. verb2 represents the second word to be found in the user JECL statement. The second verb is optional (most user JECL statements have only one verb). Since this is a positional parameter, if verb2 is not coded, the intervening comma must be present.
Represents the action the you want JES2 to take. The possible actions are:
JES2 does not take any action.
The JECL statement is passed to JES for processing.
The job is to be canceled.
The job is canceled and purged.
The default for this subparameter is IGNORE.
Represents the action you want BMC ThruPut Manager to take. The possible actions are:
BMC ThruPut Manager does not take any action.
BMC ThruPut Manager processes the statement. If the optional PROC subparameter is included, the statement is allowed within JCL procedures for batch jobs.
The JECL statement is presented to BMC ThruPut Manager EXIT 19, if the exit is active. If the optional PROC subparameter is included, the statement is allowed within JCL procedures for batch jobs.
Indicates that you want the statement to be mapped into a JECL statement. When the JES2XLATE keyword is present, you must provide at least new-verb1 as a parameter. Note that a single verb statement can be mapped into a two verb statement, and that a two verb statement can be mapped into a single verb statement.
Indicates the first target verb. This parameter is mandatory.
Indicates the second target verb. This parameter is optional.
Indicates that you want the statement to be mapped into a BMC ThruPut Manager JECL (//*+) statement. When the XLATE keyword is present, you must provide at least new-verb1 as a parameter. Note that a single verb statement can be mapped into a two verb statement, and that a two verb statement can be mapped into a single verb statement.
Indicates the first target verb. This parameter is mandatory.
Indicates the second target verb. This parameter is optional.
The default for this subparameter is PROCESS without the PROC subparameter.
The automatic JECL mapping feature is not limited to BMC ThruPut Manager JECL statements. You can translate any of your user-defined JECL into equivalent BMC ThruPut Manager or JES2 statements, or vice-versa.
If desired, you can also explicitly exclude specific JECL statements from procedures. To do this, use the JECL keyword of the TMPARM statement:
The PROCESS subparameter ensures that the statement is passed to BMC ThruPut Manager. To disallow a JECL statement completely, code:
Note that these techniques apply equally to BMC ThruPut Manager JECL statements. For example, you could use this method to fail jobs that attempt to use JBS ACTIVATE statements.
BMC ThruPut Manager JECL Statements within JCL Procedures
It is possible to include BMC ThruPut Manager JECL statements (//*+) within JCL procedures, but not JES2 JECL (/*) statements.
- For started tasks, BMC ThruPut Manager allows all BMC ThruPut Manager JECL.
- For batch jobs, BMC ThruPut Manager allows only the JBS BIND and JBS MESSAGE statements, JLS statements, and DBS statements. Other JECL statements, such as JBS ACTIVATE, user-defined statements, or JSS statements, are not permitted.
BMC ThruPut Manager JECL statements within an in-stream procedure are processed only if the procedure is called within the job.
Installation EXIT 19
If the automatic mapping mechanism cannot handle your situation, you can resort to an installation exit. BMC ThruPut Manager’s EXIT 19 allows you to process JECL statements and alter them in any way that is needed. This occurs when one of your JECL statements has to be mapped into more than one BMC ThruPut Manager’s JECL statements or when you have to combine two or more of your JECL statements into one BMC ThruPut Manager’s JECL statements.
In addition, EXIT 19 allows you to process your own JECL statements by passing information through to your JAL. To process your JECL statements in EXIT 19, you must use the JECL keyword in TMPARM JES2 statement to indicate which statement you want captured. Of course, you must also activate EXIT 19.