Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Duplicate runs using default cache lock #226

Open
dom-devel opened this issue Jan 3, 2023 · 0 comments
Open

Duplicate runs using default cache lock #226

dom-devel opened this issue Jan 3, 2023 · 0 comments

Comments

@dom-devel
Copy link

What's the issue

We're having some issues where two crons end up running at the same time.

We're using the cache lock (i.e. default) and version: ==0.5.1

It seems like there was an update to the FILE_LOCK cache Simplifies the file-based lock mechanism and fixes the race condition, but none as far as I could see to the cache lock.

Is this a known issue?

Details
We've got a cron job which runs every 10 minutes.

RUN_EVERY_MINS = 10
schedule = Schedule(run_every_mins=RUN_EVERY_MINS)

Which is then called by our cron runner every 10 minutes.

*/10 * * * *

This seems to work out at the cron running about 3-4 times an hour. I'd guess there is some sort of time mismatch?

image

This wouldn't be the end of the world, except occasionally it does this and triggers the cron twice approximately 1 minute apart:

image

And when this happens, it seems that the cron seems to run simultaneously despite not having parallel runs enabled.

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant