Repository navigation
docs(adr): ADR-0028 — Phase-2 runtime: concurrent connections, admission limits, graceful shutdown - #122
Conversation
…ion limits, graceful shutdown Extends ADR-0022 for the Phase-2 runtime/concurrency workstream (#109): JoinSet-based concurrent accept loop, half-open and per-source admission caps with documented defaults, first-party token-bucket rate limiting, and SIGTERM/SIGINT graceful shutdown with a drain deadline. Discharges the threat-model §5.1.3 test handles and closes the pre-auth availability ceiling accepted in Phase 1. Status: Proposed — flips to Accepted when the implementing PRs merge. Claude-Session: https://claude.ai/code/session_01J2SZwLuDm1KjfYyPM8npTa Signed-off-by: Gonzalo Fleming <[email protected]>
|
Review complete. No blocking findings. This is a well-constructed ADR. Design soundness against the five MANIFIESTO commitments
Threat-model alignment
Procedural
Classification: ready to merge as-is. |
There was a problem hiding this comment.
Pull request overview
Adds ADR-0028 (Proposed) to record the Phase-2 runtime/concurrency decision that extends ADR-0022: moving from the Phase-1 spawn-and-join accept loop to concurrent connection handling with explicit admission control and graceful shutdown semantics.
Changes:
- Defines a concurrent accept loop design using
tokio::task::JoinSetandselect!for accept / task reaping / shutdown. - Specifies admission-control defaults (global cap, half-open caps, per-source caps, per-source token bucket) and the
connection.refusedlog event for refusals. - Specifies graceful shutdown behavior (SIGINT/SIGTERM → stop accept → broadcast → drain deadline → abort remainder) and the required tokio feature-set deltas.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Code reviewNo issues found. Checked for bugs and CLAUDE.md compliance. |
…ng with ADR-0024 schema Review feedback (Copilot on #122): connection.refused inherits peer_addr from the ADR-0024 connection span instead of carrying it as an event field, and the JoinError panic reason is a structured field, never interpolated into the message text. Claude-Session: https://claude.ai/code/session_01J2SZwLuDm1KjfYyPM8npTa Signed-off-by: Gonzalo Fleming <[email protected]>
|
Review complete. No blocking findings. Design soundness
Threat-model alignment
Addressing prior review commentsThe copilot-reviewer's two flags are already handled by the ADR text:
Procedural
Classification: ready to merge as-is. |
… feature delta Second Copilot pass on #122: Date follows the Proposed-era house style (TBD until acceptance, as ADR-0022 did), and the feature-set delta is signal only — quantumssh-core already enables tokio macros, so the 'previously binary-only' claim was wrong. Claude-Session: https://claude.ai/code/session_01J2SZwLuDm1KjfYyPM8npTa Signed-off-by: Gonzalo Fleming <[email protected]>
|
RFC-0010 resolves. Now let me give my final review. Review complete. No blocking findings. This ADR is well-constructed and all prior review flags are addressed. Design soundness against the five MANIFIESTO commitments
Threat-model alignment
Procedural
Classification: ready to merge as-is. |
…ce (#126) The note's banner and workstream map predated RFC-0010's acceptance (#116) and ADR-0028 (#122, amended #123): the banner claimed no Phase-2 governance existed beyond RFC-0008, and the config/runtime rows still pointed at to-be-written lanes. Refresh both, and add the connection.refused event to the freeze checklist — ADR-0028 §Consequences names it a freeze item, but the checklist here never picked it up. Mutable-note lane per ADR-0027; nothing here decides anything. Claude-Session: https://claude.ai/code/session_01J2SZwLuDm1KjfYyPM8npTa Signed-off-by: Gonzalo Fleming <[email protected]>
What
Adds ADR-0028 (Status: Proposed), the governance piece for the Phase-2 runtime/concurrency workstream tracked in #109 — the ADR extending ADR-0022 that the scoping note (
docs/plans/phase2-scoping.md) maps for this lane. Per project practice, the ADR lands before any implementation.The decision it records
tokio::task::JoinSet(select!over accept / join_next / shutdown), preserving ADR-0022's panic-isolation and audit-trace guarantees.connection.refusedevent (freeze-checklist interaction with ADR-0024 noted).signalfeature, SIGTERM/SIGINT → stop accepting → broadcast → drain deadline (30 s) → abort remainder. The systemd ADR will consume this.signal, plusmacrosonquantumssh-core. The tokio 1.51 LTS pin (chore(deps): restore the ADR-0022 tokio LTS pin and enforce it in dependabot #119) is untouched.Defaults are anchored on OpenSSH
MaxStartupsprior art and marked not yet validated under load — the §5.1.3 slow-handshake test scenario is the acceptance gate for the implementation.Why Proposed, not Accepted
Follows the Phase-1 pattern (#86): forward-looking ADRs land as Proposed and flip when their implementing PRs merge.
Refs #109.
https://claude.ai/code/session_01J2SZwLuDm1KjfYyPM8npTa