From 8fd91b7b1561c95648f9e270e3adc30ab8cd63b2 Mon Sep 17 00:00:00 2001 From: npeter83 Date: Sat, 17 Oct 2026 23:15:17 +0200 Subject: [PATCH] fix(scheduler): keep run history 180 days, as long as the audit log kept the runs it moved over --- backend/app/config.py | 7 ++++--- frontend/src/i18n/locales/en/config.json | 2 +- frontend/src/i18n/locales/hu/config.json | 2 +- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/backend/app/config.py b/backend/app/config.py index f5b66200..a77eb37c 100644 --- a/backend/app/config.py +++ b/backend/app/config.py @@ -268,9 +268,10 @@ class Settings(BaseSettings): # YouTube quota history (quota_events): days kept (0 = forever). A year, so the admin usage view's # longest window (365 days) stays whole; the same daily cleanup job prunes it. quota_retention_days: int = 365 - # Background-run history (job_runs): days kept (0 = forever). Every run is a row (~1–1.5k a day - # at the default intervals), so a month; the same daily cleanup job prunes it. - job_run_retention_days: int = 30 + # Background-run history (job_runs): days kept (0 = forever). The audit log's 180, which is how + # long a run lived there before it moved here: ~1.8k rows a day at the default intervals + # (measured 2026-10-17), ~320k at the limit. The same daily cleanup job prunes it. + job_run_retention_days: int = 180 # On-disk layout: "plex" (Channel/Season YYYY/… [id].ext + .nfo/poster) or "flat". download_layout: DownloadLayout = "plex" # Default SponsorBlock (skip sponsor segments) for new custom profiles. diff --git a/frontend/src/i18n/locales/en/config.json b/frontend/src/i18n/locales/en/config.json index 2a73c870..0b516fbb 100644 --- a/frontend/src/i18n/locales/en/config.json +++ b/frontend/src/i18n/locales/en/config.json @@ -172,7 +172,7 @@ }, "job_run_retention_days": { "label": "Run history (days)", - "hint": "How long the history of background runs (scheduled, run now, a channel's full history) is kept before the cleanup job prunes it. 0 = keep forever. Default 30." + "hint": "How long the history of background runs (scheduled, run now, a channel's full history) is kept before the cleanup job prunes it. 0 = keep forever. Default 180." }, "log_level": { "label": "Log level", diff --git a/frontend/src/i18n/locales/hu/config.json b/frontend/src/i18n/locales/hu/config.json index f2db4b2a..de9be7a9 100644 --- a/frontend/src/i18n/locales/hu/config.json +++ b/frontend/src/i18n/locales/hu/config.json @@ -172,7 +172,7 @@ }, "job_run_retention_days": { "label": "Futási előzmények (nap)", - "hint": "Meddig maradnak meg a háttérfutások (ütemezett, azonnali, egy csatorna teljes előzménye) adatai, mielőtt a takarító feladat törli őket. 0 = örökre. Alapérték 30." + "hint": "Meddig maradnak meg a háttérfutások (ütemezett, azonnali, egy csatorna teljes előzménye) adatai, mielőtt a takarító feladat törli őket. 0 = örökre. Alapérték 180." }, "log_level": { "label": "Naplózási szint",