ESP Workload Automation

 View Only
  • 1.  Run Frequency definition

    Posted Jul 23, 2024 08:54 AM

    Hi Team,

    I want to define a job to run on  Monday to Saturday At 5:00 AM and should not run on holidays. But the Event loads at 8:00 AM Daily

    Ideally,
    1.Monday Job triggers at 5:00 but runs at Tuesday 5:00 AM
    2.Tuesday Job triggers at 5:00 but runs at Wednesday 5:00 AM
    3.Wednesday job triggers at 5:00 but runs at Thursday 5:00 AM
    4.Thursday Job triggers at 5:00 but runs at Friday 5:00 AM
    5.Friday job triggers at 5:00,but runs at Saturday 5:00 AM
    6.saturday job triggers at 5:00,but runs at Sunday 5:00 AM  >> Sunday job should not trigger.

    by adding RUN DAILY less 1 day makes the job not to trigger at 5:00 on Sunday?

    Help is appreciated..!

    Thanks in advance..!

    thanks,
    Vinothini



  • 2.  RE: Run Frequency definition
    Best Answer

    Broadcom Employee
    Posted Jul 24, 2024 05:54 AM
    Edited by vinothini G Aug 16, 2024 08:51 AM

    Hi Vinothini,

    RUN statement for the jobs are used only for selection for a job run for a particular day.
    Although you can specify time the the criteria for it, only the day will be used. - RUN MONDAY results in the same selection as RUN MONDAY 5:00 AM

    If you want a job in a generation of a application to be submitted the next day (after 21 hours as in you example), I would recommend looking into the DELAYSUB statement It also has alias - EARLYSUB.
    In your case something like this should work:

    JOB  TEST /* select job on MONDAY but wait with submission to Tue 5am */
    RUN MON
    DELAYSUB TUE 5AM
    ENDJOB


    When the application is generated by triggering the EVENT on Monday, the job will get selected due to RUN statement, but will in waiting status until Tuesday 5 AM. You will still see it active in CSF or other views, but will not be executed on JES (for mainframe job) or on Agent if it is a distributed one. This way you can define each of those jobs.

    If what you need is 1 job for all of these days you can write it more generically like this:

    JOB TEST              
    NORUN SUN
    NORUN HOLIDAY /* job will be selected on all days except Sunday, it won't run on holidays (based on your calendar definitions) */    
    DELAYSUB TOMORROW 5AM 
    ENDJOB                

    Note that the selection is for the day when event is triggered and application is generated, the fact that the job will wait until next day for submission will not affect it.

    Also note that if your goal is not to execute the job on holiday instead of not trigger and generate new application on holiday, you would need to add new criteria to the selection - NORUN HOLIDAY LESS 1 DAY



    ------------------------------
    Jonáš Dusil
    Product Owner | ESP Workload Automation | Mainframe Software Division
    ------------------------------



  • 3.  RE: Run Frequency definition

    Posted Aug 16, 2024 11:12 AM

    Thanks so much for information..!