Repository navigation
feat(relay): make capacity controls observable - #122
Merged
abruption merged 1 commit intoSep 21, 2026
Merged
Conversation
abruption
force-pushed
the
chore/115-control-migrations
branch
from
September 21, 2026 01:59
02e6a8f to
2e72b26
Compare
abruption
force-pushed
the
feat/114-relay-capacity-metrics
branch
from
September 21, 2026 01:59
b7028bc to
517d730
Compare
abruption
force-pushed
the
chore/115-control-migrations
branch
from
September 21, 2026 02:01
2e72b26 to
bee4634
Compare
abruption
force-pushed
the
feat/114-relay-capacity-metrics
branch
from
September 21, 2026 02:01
517d730 to
320edab
Compare
abruption
force-pushed
the
chore/115-control-migrations
branch
from
September 21, 2026 02:03
bee4634 to
82da76c
Compare
abruption
force-pushed
the
feat/114-relay-capacity-metrics
branch
from
September 21, 2026 02:03
320edab to
0bd0fc9
Compare
abruption
force-pushed
the
chore/115-control-migrations
branch
from
September 21, 2026 05:36
82da76c to
d52fdf3
Compare
abruption
force-pushed
the
feat/114-relay-capacity-metrics
branch
from
September 21, 2026 05:36
0bd0fc9 to
5a62090
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The hosted relay kept fixed Alpha-era limits and its authenticated API retained every user rate bucket for the life of the process. This change preserves the existing defaults while making them explicit, validated safety bounds; bounds and cross-limit relationships fail closed at startup.
The Python relay now distinguishes handshake rate pressure (429) from pending-session and connection capacity (503), without burning a fresh admission proof or discarding an issued one-use session. It tracks only non-identifying aggregate counters and serves them from a separate
127.0.0.1metrics listener. The control service validates that fixed schema and merges it only into the dedicated Authelia-protected admin listener. The public relay hostname receives no metrics route. User rate buckets are capped and expired deterministically.The KR reference retains the current limits (20 handshakes/s, 100 pending sessions, 10 global, 8/user, 4/device, 32 MiB/direction), adds the loopback metrics wiring and admin capacity cards, and documents how those limits fit below the 256 MiB/64-task/256-FD unit envelope. Generic sizing guidance treats limits as safety bounds rather than user-count guarantees.
Validation:
This PR is stacked on #121 so the capacity configuration uses the versioned control schema introduced there.
Closes #114