question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Recurring task starting at fixed delays

See original GitHub issue

One can, at the moment, create a RecurringTask that gets rescheduled with FixedDelay, but it is indeed a fixed delay between a previous completion of the task and new scheduled completion.

That means that if a task is a recurring task with FixedDelay of 5 seconds, and the task is scheduled for 14:00:00.00, actually starts at 14:00:00.05 and takes 0.3 s to execute, the next execution will get scheduled for execution after 14:00:05.08.

Is there a way to achieve recurring task that will get scheduled for 14:00:00.00, then 14:00:05.00, then 14:00:10.00 etc., without a time drift caused by execution time and a delay between planned execution time and actual picking of the task?

Issue Analytics

  • State:open
  • Created 6 years ago
  • Comments:13 (8 by maintainers)

github_iconTop GitHub Comments

2reactions
kagkarlssoncommented, Apr 24, 2017

I have exposed the Execution in the ExecutionContext in master now. See commit c3528353dd12b5e8c2be8d5d7d1b229b70eb4a30

1reaction
kagkarlssoncommented, Apr 25, 2019

I know this thread is old, but we recently fixed a bug which limited the throughput of the scheduler if that is of interest.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to schedule tasks in Java to run for repeated fixed-delay ...
This method schedules tasks for repeated fixed-delay execution, beginning after the specified delay. In fixed-delay execution, ...
Read more >
Delay Task Generation After Completing Recurring Task
For recurring tasks you create is there a way to delay the regeneration of the subsequent task for next due date period to...
Read more >
Create recurring tasks - Microsoft Support
Add recurring tasks to a project for actions that repeat on a regular schedules. You can also create recurring reminders by adding repeating...
Read more >
How to Schedule a task for repeated execution ... - YouTube
How to Schedule a task for repeated execution, beginning after specified delay ? | Timer. Watch later. Share. Copy link.
Read more >
java - How do I schedule a task to run at periodic intervals?
Schedules the specified task for repeated fixed-rate execution, beginning after the specified delay. Subsequent executions take place at ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found