diff --git a/internal/store/sqlitestore/cron_scheduler.go b/internal/store/sqlitestore/cron_scheduler.go index 3f56e16b..3b92d78d 100644 --- a/internal/store/sqlitestore/cron_scheduler.go +++ b/internal/store/sqlitestore/cron_scheduler.go @@ -70,6 +70,7 @@ func (s *SQLiteCronStore) InvalidateCache() { } // recomputeStaleJobs fixes enabled jobs on startup: +// - Resets any jobs stuck in 'running' state from a previous crash. // - Recomputes next_run_at for jobs where it is NULL (crashed mid-execution). // - Advances past-due jobs (next_run_at < now) to their next future run time, // preventing a flood of all missed jobs firing simultaneously after downtime.