Avoid redundant full scan after warm restart

This commit is contained in:
Codex committed 2026-10-08 21:58:28 +02:00
1 parent 8ac27e1f3d
commit c8dd46d0fb
3 files changed
+23 -8

No files matched your search

+2 -1
View File
@@ -57,7 +57,8 @@ server. The daemon publishes complete folders atomically and increments a durabl
revision; the reader polls that revision and refreshes changed manga after publication.
The reader restores a disposable full-index snapshot at startup so browsing need not
wait for a filesystem walk. Shallow directory stamps identify changed manga; a
background and daily full reconciliation catches in-place manual edits.
daily full reconciliation catches in-place manual edits. The last full-scan time
survives restarts, so restarting does not itself force another complete walk.
| Path | Lines | Responsibility |
|------|------:|----------------|
+5
View File
@@ -33,6 +33,11 @@ MangaCircus does not copy or convert anything. "Import" means **indexing the lib
| **Rescan** (Settings → Admin, or `POST /api/admin/rescan {}`) | On demand; the request returns when the scan is done | used |
| **Full rescan** (`POST /api/admin/rescan {"full":true}`) | On demand | ignored: every image header is read again |
The saved index records when its last full reconciliation finished. A warm restart
does a shallow check but does not reset the daily full-scan clock; if that scan is
overdue, the reader schedules it within a minute. Set `FULL_SCAN_INTERVAL=0` to
disable automatic full reconciliations, while retaining admin Rescan.
Scans are **single-flight**. A trigger during a scan queues one coalesced follow-up,
with a full reconciliation taking precedence over a shallow check. Publication
revisions trigger a shallow check; if no changed directory is visible, the reader