0

I want to achieve below requirement - Say I have a trigger named RunBatchJob

Weekdays: Monday - Friday I want to schedule this trigger to run on below times: Recurrence -> Every 5 Minutes between 06:00AM until 10:00 PM Recurrence -> Every 30 Minutes between 10:01 PM until 05:59 AM

Weekends: Saturday, Sunday I want to schedule this trigger to run on below times: Recurrence -> Every 10 Minutes between 06:00AM until 10:00 PM Recurrence -> Every 1 Hour between 10:01 PM until 05:59 AM

This used to be particularly easy on SQL server jobs, can anyone please advise me how to do it on ADF?

Vivek KB
  • 49
  • 6
  • Maybe someone else knows but I don't believe you can do directly with the ADF Triggers. You could do with a Logic App (or several) that trigger the ADF. You could put the logic in a file of database and the Logic App (running every 5 minutes) would decide if it should trigger the ADF or not based on that logic. You could do similar with Azure functions too. – Scott Mildenberger Nov 07 '22 at 17:35
  • I would definitely look into Logic Apps to handle an irregular Trigger pattern. Here's an answer you may find useful: https://stackoverflow.com/questions/62134686/can-i-trigger-my-azure-data-factory-pipeline-in-5-working-day-between-9-am-to-6/62137667#62137667 – Joel Cochran Nov 07 '22 at 18:39

1 Answers1

1

You can separate the triggers into 4 cases. Use a scheduled trigger for 1 week occurrence. Then you can enumerate all the combinations of trigger times in each trigger.

Here is the example for the 1st case(Mon-Fri Every 5 Minutes between 06:00 AM until 10:00 PM) enter image description here

You can just repeat the idea for 2nd case(Mon-Fri Every 30 Minutes between 10:01 PM until 05:59 PM) enter image description here

ray
  • 11,310
  • 7
  • 18
  • 42