Crons: Disallow missed margin larger than the smallest schedule gap
- Dominant language
- Python
- Stars
- 44.8k
- Forks
- 4.9k
- Avg merge
- 1d 5h
- Merged PRs (30d)
- 624
Description
Take a monitor that is run once an hour as an example

Imagine now that I've configured the monitor to have a 'missed margin' of 2 hours. This would look like this:

Importantly note that the margins are overlapping each other
So now imagine that the first checkin does not happen on time. The red line indicates the current time. We have not checked in, but we have also not marked anything as missing due to the 2 hour check-in margin.

What should happen now if a check-in occurs? does it complete the checkin at 12:00?
If yes, then what happens when the next check-in occurs? It may have been that the users cron scheduler was off for the period of 12:00 → 1:00, and it may be configured such that that task was just skipped, and the checkin we got a little after 1:00 was intended to be for 1:00. Now if we continue with our logic that the next checkin that happens at 2:00 should actually be for 1:00 **that would be incorrect**.
Contributor guide
Assessment
This issue has not been assessed yet.