1.3.0 - Release Highlights
Changes affecting tests running locally or on the Galasa Service
- z/OS Batch Manager: Added a new
submitJobWithSuppliedJobcard(String jcl)method to theIZosBatchinterface that submits JCL which already contains its own JOB statement, such as a member of a JCL library. Previously the manager always generated a JOB statement and put it in front of the supplied JCL, so JCL that contained its own JOB statement was rejected by JES with a JCL error. Tests no longer need to strip the JOB statement and its continuation records from the JCL, or re-express its attributes using aZosBatchJobcard. This is supported by both the z/OS MF and RSE API implementations of the z/OS Batch Manager. See the z/OS Manager documentation for examples. - The job name is taken from the JOB statement in the supplied JCL and is used to track the job, so
waitForJob(),getRetcode()and the retrieval of spool files work in the same way as for other jobs. A Galasa provisioned job name is not used. - The JOB statement can be continued over several records. The first record that is not blank or a comment (
//*) must be the JOB statement. If a valid JOB statement is not found, aZosBatchExceptionis thrown and the JCL is not submitted. - A
ZosBatchJobcardcannot be used to override values in the JOB statement, and the default input class, message class and message level CPS properties are not applied. Everything required must be specified in the JOB statement. - If the
zosbatch.batchjob.[imageid].use.sysaffCPS property istrue, the manager still adds a/*JOBPARM SYSAFF=[imageid]record, immediately after the last record of the JOB statement. It does not add the record if the supplied JCL already contains a/*JOBPARMrecord that specifiesSYSAFF=. -
The existing
submitJobmethods are unchanged. The JCL passed to them must still not include a JOB statement. -
z/OS Batch Manager: Added a new
ZosBatchJobnamesclass in thedev.galasa.zosbatchpackage so that a test can choose the job name that JES sees, for example to run a library member under its documented name. Previously a test could only use a name generated by Galasa, either through the@ZosBatchJobnameannotation or by passingnulltosubmitJob. This is supported by both the z/OS MF and RSE API implementations of the z/OS Batch Manager. See the z/OS Manager documentation for examples. ZosBatchJobnames.exact(String name)returns anIZosBatchJobnamewith exactly the supplied name, in upper case, that can be passed tosubmitJob. Galasa does not make this name unique, so tests that run at the same time on the same z/OS system and use the same name can collide.ZosBatchJobnames.randomWithPrefix(String prefix)returns anIZosBatchJobnamethat starts with the supplied prefix, followed by random characters to make the name 8 characters long. The name is random but not guaranteed to be unique, and a longer prefix leaves fewer random characters.- A name that is empty, longer than 8 characters or contains characters that are not valid in a job name is rejected with a
ZosBatchException. A prefix forrandomWithPrefixcan be up to 7 characters. - Added a
submitJob(String jcl)method to theIZosBatchinterface that submits the JCL with a job name provisioned by the Manager. It is the same as passingnullas the job name tosubmitJob, which is unchanged. - The existing
@ZosBatchJobnameannotation is unchanged and still provides a unique generated name.