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

Always preserve job records created by cron #767

Merged
merged 1 commit into from
Dec 10, 2022
Merged

Conversation

bensheldon
Copy link
Owner

@bensheldon bensheldon commented Dec 10, 2022

Connects to #731. This is necessary because Cron's duplicate-prevention strategy uses a uniquely indexed column; in order for that to work, jobs can't be immediately deleted because that would allow another process to insert a record again.

@bensheldon bensheldon temporarily deployed to goodjob-preserve-cron-bgywtgav December 10, 2022 22:22 Inactive
@bensheldon bensheldon merged commit c729589 into main Dec 10, 2022
@bensheldon bensheldon deleted the preserve_cron branch December 10, 2022 22:49
@bensheldon bensheldon added the bug Something isn't working label Dec 10, 2022
@zarqman
Copy link
Contributor

zarqman commented Dec 11, 2022

Confirming that this does successfully prevent dupe cron jobs as discussed in #731. Thanks for resolving this! 🎉

Do I see correctly that cron job executions will be kept for the value of cleanup_preserved_jobs_before_seconds_ago, so with the default of 14 days and an every-15-minutes cron entry, it'll preserve ~1300 records?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Development

Successfully merging this pull request may close these issues.

2 participants