peter
ce10e67e13
feat(downloads): M3 — per-user quota + retention GC
- downloads/quota.py: per-user limits (DownloadQuota row or sysconfig defaults; unlimited
bypass), footprint = distinct ready-asset bytes the user holds, check_enqueue (max_jobs +
max_bytes hard at enqueue), at_concurrency_limit (worker-side max_concurrent), usage snapshot
- downloads/gc.py: run_download_gc — pre-expiry warning (once, gc_notified flag), TTL deletion
(files + row; FK SET NULL orphans holders' jobs -> 'expired'), LRU eviction over a total-cache
cap; notifies holders on each event
- migration 0038: media_assets.gc_notified
- config/sysconfig: download_total_max_bytes (0=unlimited) in the downloads group
- service.enqueue enforces quota; worker claim skips users at their concurrency limit
- scheduler: download_gc job registered (default 360 min, admin-tunable)
Verified on localdev: footprint accounting, max_jobs block, pre-expiry warning (notifies all
holders), TTL deletion (asset+files gone, dirs pruned, jobs orphaned, holders notified).
2026-07-03 00:26:40 +02:00
..
2026-06-11 01:01:37 +02:00
2026-06-11 01:22:07 +02:00
2026-06-11 01:57:19 +02:00
2026-06-11 02:11:02 +02:00
2026-06-11 03:07:49 +02:00
2026-06-11 04:15:25 +02:00
2026-06-11 23:07:09 +02:00
2026-06-12 01:43:07 +02:00
2026-06-12 02:47:55 +02:00
2026-06-14 18:40:05 +02:00
2026-06-15 14:37:09 +02:00
2026-06-15 15:33:53 +02:00
2026-06-15 23:00:56 +02:00
2026-06-16 09:17:14 +02:00
2026-06-16 15:58:23 +02:00
2026-06-18 03:20:17 +02:00
2026-06-18 03:20:17 +02:00
2026-06-18 04:37:08 +02:00
2026-06-19 02:16:42 +02:00
2026-06-19 11:48:11 +02:00
2026-06-19 12:22:36 +02:00
2026-06-19 14:03:11 +02:00
2026-06-19 19:52:12 +02:00
2026-06-19 19:52:02 +02:00
2026-06-21 00:38:47 +02:00
2026-06-25 22:05:35 +02:00
2026-06-25 22:05:35 +02:00
2026-06-29 02:01:31 +02:00
2026-06-29 02:30:37 +02:00
2026-06-30 00:39:09 +02:00
2026-06-30 00:39:09 +02:00
2026-06-30 02:00:38 +02:00
2026-06-30 02:52:44 +02:00
2026-07-01 00:42:32 +02:00
2026-07-01 03:17:36 +02:00
2026-07-02 23:57:40 +02:00
2026-07-02 23:57:40 +02:00
2026-07-03 00:26:40 +02:00