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

Job system should clean up jobs that are "dead in the water" #1685

Open
einari opened this issue Jan 31, 2025 · 0 comments
Open

Job system should clean up jobs that are "dead in the water" #1685

einari opened this issue Jan 31, 2025 · 0 comments
Labels
jobs Issues related to the job system

Comments

@einari
Copy link
Contributor

einari commented Jan 31, 2025

Add functionality to JobsManager that cleans up jobs that are typically stuck in preparation and has no steps and was started before a given time threshold (configurable).

We should also add a TimeStamp on the JobState for when it was created - this time stamp is the one we should use as time threshold.

The goal is not to clean up jobs that are possibly just starting up. So we add a time threshold to distinguish from these. E.g. jobs that hasn't started in an hour (on preparing steps state) are candidates. If they don't then have any steps or any progress, they can be be cleared out.

The JobsManager should do this on startup, but also have a scavenger "job" - basically a timer that runs on a regular cadence (e.g. every hour - configurable).

@einari einari added the jobs Issues related to the job system label Jan 31, 2025
@einari einari moved this to Todo in Current Work Jan 31, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
jobs Issues related to the job system
Projects
Status: Todo
Development

No branches or pull requests

1 participant