e5313342ba
Virtual merges expire after 60s and the next request blocks on every member. One slow member (a large github_rpm remote) makes the re-merge outlast dnf's 30s timeout. - add `serve_stale` to remotes (model, v2 API, migration 0008, UI, TUI), default false - serve a flagged member's last good fetch to rpm/deb/alpine merges at once - refresh it in the background, single-flighted, detached from the request - block on the member again once its copy is over an hour old, or the flag is off - prune copies with their merge cache; drop refreshes for evicted entries Reviewed-on: #167 Co-authored-by: unkin-agent <unkin-agent@unkin.net> Co-committed-by: unkin-agent <unkin-agent@unkin.net>
4 lines
201 B
SQL
4 lines
201 B
SQL
-- serve_stale lets a virtual merge a member's previous index while that member
|
|
-- refreshes in the background.
|
|
ALTER TABLE remotes ADD COLUMN IF NOT EXISTS serve_stale BOOLEAN NOT NULL DEFAULT FALSE;
|