mirror of
https://relay.ngit.dev/npub15qydau2hjma6ngxkl2cyar74wzyjshvl65za5k5rl69264ar2exs5cyejr/ngit-grasp.git
synced 2026-10-05 15:08:24 +00:00
Large startup sources held the manager through reconciliation and hundreds of paced history requests. Already-connected peers could wait minutes for their live event processors and subscriptions to start. Move reconciliation, initial history admission, pagination and hydration retries into background jobs, bounded to eight active jobs and one per relay. Keep per-connection pacing and ledger limits. Cooldown waits release global capacity, including policy refusals with their separate deadline. Register complete request plans before sending and retain a local admission barrier until worker completion. Early EOSE cannot confirm partial coverage; failed admission retires partial requests, while hydration retry failures retain bounded missing-event recovery. Unique batch/barrier IDs and explicit cancellation isolate resets, disconnects and late completions. No new configuration or change to repository membership policy is included. Replace obsolete synchronous-admission tests with wire-level startup and fast-EOSE coverage. Assert paused peers cannot starve healthy history jobs and cancellation releases their gates. The large-history concurrency test now waits for confirmed sync status rather than total request silence, since discovery continues while the actor is responsive. Validation: 921 library tests plus the new cooldown-worker regression; 113 sync integration tests (one ignored), including the corrected large startup case; 60 purgatory tests. Focused pagination and missing-ID recovery checks also pass, as do all-target Clippy with -D warnings and formatting. Assisted-by: GPT-6