ESP Workload Automation

 View Only

 Scheduling a job with different schedule other than event

Santhosh Gollapudi's profile image
Santhosh Gollapudi posted Jan 28, 2025 10:17 AM

I have an event X that is scheduled to run hourly at 01.30, 02.30 etc between Workday - 5 and Workday + 10 of every month.

Out of these 13 jobs, I wanted 2 of them to be scheduled and executed between WD-5 and WD+4 till 12 noon only which means they should not run after 12 PM eastern on WD+4. 

Any thoughts to define this schedule ?

Chris_Elvin's profile image
Broadcom Employee Chris_Elvin

I assume that each of the jobs in the application have something similar to "RUN DAILY" or "RUN TODAY" etc so that they are selected whenever the event is triggered

For the two jobs you want to further restrict, I would use something along the lines of the following for the run-frequency

IF DAYS_TO('4TH WORKDAY OF MONTH STARTING 1ST DAY OF MONTH') >= 0 -
  OR %ESPSHH < 13 THEN RUN TODAY

The DAYS_TO part limits the job to the 1st 4 working days of the month and the %ESPSHH part limits the job to being selected only between midnight and midday

Obviously this does not exactly suit your needs, but it illustrates the principle of building complex scheduling criteria using functions such as DAYS_FROM, DAYS_TO, DAYS_BETWEEN etc and the ESP built-in scheduling variables along with the standard mathematical and logical operators.