You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Self-hosted relay: first pairing on a new identity can miss its deadline under disk load #1961
On a self-hosted relay (codeaf relay --store), the first device registration on a brand-new identity can miss the client's 20 s deadline when the disk is busy. This is the first PUT /v1/dir/devices, at pairing step 3c. The first write freezes the legacy directory, then imports it into the three local anchors, and each anchor makes durable commits. Under the same load, dev hit the deadline in 1 of 4 pairings and #1950 in 3 of 4. A retry pairs in about a second, and normal pairing takes 1–3 s. The hosted relay is not affected.
Replication
Load the disk with stress-ng --hdd 2 --hdd-bytes 1G --timeout 600s, or any sustained fsync-heavy writer.
Run make build.
Run go test -tags e2e -run 'TestPairJourney' -count=4 -v ./internal/e2e/.
Count the step 3c failures that end in context deadline exceeded.
Acceptance
Under the same load, TestPairJourney pairs on the first attempt at least as often as on dev. The fix could be:
making first-use anchor setup cheaper, for example batching its durable writes;
or completing it before the device request's deadline starts.
The deadline must not be raised to hide it. Step 3c of the journey must pass with the visible pairing confirmation, and must not need a manual retry.
Activity