fix: reap expired sessions with a periodic background sweep

The sessions table only grew — find_active ignored expired rows but nothing
deleted them, so lapsed sessions accumulated indefinitely.

- repo::session::delete_expired: indexed DELETE (sessions_expires_idx) returning
  the reaped count.
- app::build spawns a detached hourly reaper (SESSION_GC_INTERVAL) that calls it,
  independent of crawler/analysis config.

Test: delete_expired_removes_only_lapsed_sessions.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
MechaCat02
2026-07-13 20:19:41 +02:00
parent f39307232c
commit 9148e23da8
6 changed files with 93 additions and 3 deletions

View File

@@ -1,6 +1,6 @@
[package]
name = "mangalord"
version = "0.128.9"
version = "0.128.10"
edition = "2021"
default-run = "mangalord"