Skip to main content

cassub alternative

  • May 7, 2019
  • 1 reply
  • 0 views

good morning,

with mainframe express I could launch 3 jobs A, B, C and they were executed one in queue to the other

MFECL /RUNEXE %PRJ% MFJCL.EXE %JCLDIR%\\A.JCL /SUBMIT
MFECL /RUNEXE %PRJ% MFJCL.EXE %JCLDIR%\\B.JCL /SUBMIT
MFECL /RUNEXE %PRJ% MFJCL.EXE %JCLDIR%\\C.JCL /SUBMIT

in enterprise developer i have found command cassub (already present in mfe):

cassub -j %JCLLIB%\\A.JCL -R%REGION_NAME%
cassub -j %JCLLIB%\\B.JCL -R%REGION_NAME%
cassub -j %JCLLIB%\\C.JCL -R%REGION_NAME%

in this case the jobs start almost simultaneously, isn't there a system to launch jcls in sequence so that the next one starts only if the previous one is finished?

 

thanks


#EnterpriseDeveloper

1 reply

good morning,

with mainframe express I could launch 3 jobs A, B, C and they were executed one in queue to the other

MFECL /RUNEXE %PRJ% MFJCL.EXE %JCLDIR%\\A.JCL /SUBMIT
MFECL /RUNEXE %PRJ% MFJCL.EXE %JCLDIR%\\B.JCL /SUBMIT
MFECL /RUNEXE %PRJ% MFJCL.EXE %JCLDIR%\\C.JCL /SUBMIT

in enterprise developer i have found command cassub (already present in mfe):

cassub -j %JCLLIB%\\A.JCL -R%REGION_NAME%
cassub -j %JCLLIB%\\B.JCL -R%REGION_NAME%
cassub -j %JCLLIB%\\C.JCL -R%REGION_NAME%

in this case the jobs start almost simultaneously, isn't there a system to launch jcls in sequence so that the next one starts only if the previous one is finished?

 

thanks


#EnterpriseDeveloper
Whether jobs are processed in series or parallel has nothing to do with how they're submitted (unless you wait until the current job finishes before submitting the next one). It's purely a matter of whether there's an available initiator to run a queued job.

The simplest way to have your three jobs run serially is to put them in the same job class, and only start one initiator for that class.

The set of initiators available at region startup is configured on the JES tab of the server properties in the Enterprise Server Administration web UI. The job class is specified on the JOB card in the JCL, of course.

There are other alternatives, such as using a scheduler and MFBSI (Micro Focus Batch Scheduler Integration). It's actually possible to build a simple scheduler with Windows command files. But using job class and a single initiator is the simplest, and most mainframe-like, approach.