cancel
Showing results forย 
Search instead forย 
Did you mean:ย 

Workato Scheduler

yu-shao
Deputy Chef I
Deputy Chef I

Hi I am a newbie here. If I set a scheduler to trigger every 5 minutes, but the whole recipe is taking more than 5 minutes to finish. I was wondering what is happening behind the scene. The next trigger will be exactly after 5 minutes or it won't trigger until the previous job finishes. If the next trigger runs and the previous job has not finished yet, is it gonna have a new job running while the previous job is still running?

7 REPLIES 7

lisa-willis
Deputy Chef I
Deputy Chef I

If the trigger for the recipe is every 5 minutes, it will kick off the recipe every 5 minutes.

 

jblanchett
Deputy Chef III
Deputy Chef III

It depends on the concurrency settings in your recipe. See Settings when you're viewing a recipe. If your concurrency is set to 1, then only one instance of the recipe can be running at the same time.


If concurrency is 1 and job 1 runs at t0 and ends at t0 + 6 min, I'm unsure if job 2 starts at t0 + 6 min or t0 + 10 min, but you could easily test this by creating a recipe that runs every 5 minutes, and has 1 step that is wait for 6 min (see scheduler app), and checking when the 2nd job gets kicked off.

With concurrency set at 1 (or defaulted to 1), I believe the 2nd job will kick off as soon as the first one completes at t0 + 6. I am pretty sure the 2nd job is placed in a queue at t0 + 5 (trigger frequency) and waits to run once a "worker" becomes available, which occurs at t0 + 6 when job 1 completes. At t0 + 10, the 3rd job would be queued up, assuming the trigger condition is satisfied and there is data to process.

Agreed with Gary. Similarly, if you have concurrency = 1 and job is triggered from a record update in another system like Salesforce, it's possible that if that record updates again after the job was queued due to a previous job still running then you could end up with duplicate jobs if jobs are queuing up in the backend. It's best to pay attention to your schedule/polling frequency and adjust it so that it doesn't run more frequently than how long the job actually takes to run.