Skip to content

feat: add connection counter to daemon server loop - #2430

Merged
oferchen merged 1 commit into
masterfrom
feat/connection-counter
Feb 22, 2026
Merged

oferchen merged 1 commit into
masterfrom
feat/connection-counter

Conversation

@oferchen

Copy link
Copy Markdown
Owner

Summary

  • Add atomic ConnectionCounter with RAII ConnectionGuard to track active daemon connections
  • Integrate counter into both single-listener and dual-stack accept loop paths
  • Each worker thread holds a guard that decrements the counter on completion or panic
  • Foundation for max-connections enforcement (Expose negotiation detector role helpers #238)

Test plan

  • 10 new unit tests for counter behavior, RAII guard, and concurrent access
  • All 22,074 tests pass
  • cargo fmt, clippy clean

Add atomic ConnectionCounter with RAII ConnectionGuard to track active
daemon connections. Each worker thread holds a guard that decrements
the counter on completion or panic. Needed for max-connections enforcement.
@oferchen
oferchen merged commit 83c3ac3 into master Feb 22, 2026
9 checks passed
@github-actions github-actions Bot added the enhancement New feature or request label Feb 22, 2026
@oferchen
oferchen deleted the feat/connection-counter branch February 22, 2026 12:33
oferchen added a commit that referenced this pull request May 1, 2026
Add atomic ConnectionCounter with RAII ConnectionGuard to track active
daemon connections. Each worker thread holds a guard that decrements
the counter on completion or panic. Needed for max-connections enforcement.
oferchen added a commit that referenced this pull request May 5, 2026
Add atomic ConnectionCounter with RAII ConnectionGuard to track active
daemon connections. Each worker thread holds a guard that decrements
the counter on completion or panic. Needed for max-connections enforcement.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant