test(reliability): add connect/disconnect soak load test (Week 4) - #64
test(reliability): add connect/disconnect soak load test (Week 4)#64Harxhit wants to merge 1 commit into
Conversation
Adds a Socket.IO connect -> (optional joinRoom) -> disconnect churn driver to validate server-side resource cleanup (no leak) under sustained connection turnover, plus a README documenting the run + leak-detection procedure. - load-test/connect-disconnect-soak.js — churn driver; reports connect/join latency, success/failure, throughput; optional --join and --metricsUrl - load-test/results/CONNECT-DISCONNECT-SOAK.md — how to run, args, and the server-side RSS/resource baseline procedure for detecting leaks Note: authored by Claude (Anthropic) via Claude Code. Not yet executed against a live backend — results section is a placeholder, not fabricated. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
There was a problem hiding this comment.
2 issues found across 2 files
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="load-test/connect-disconnect-soak.js">
<violation number="1" location="load-test/connect-disconnect-soak.js:139">
P2: When `--join true` is used, this branch only sends `joinRoom` before disconnecting, so it never allocates a viewer transport or consumer. Run the remaining viewer signaling steps in this soak, or narrow the cleanup claim to room-viewer state.</violation>
<violation number="2" location="load-test/connect-disconnect-soak.js:258">
P2: When connections or joins fail, this command still exits with status 0, so CI or automation cannot detect a failed soak. Exit nonzero when cycles are incomplete or any connect/join error is recorded.</violation>
</file>
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
|
|
||
| results.connectMs.push(performance.now() - connectStart); | ||
|
|
||
| if (JOIN) { |
There was a problem hiding this comment.
P2: When --join true is used, this branch only sends joinRoom before disconnecting, so it never allocates a viewer transport or consumer. Run the remaining viewer signaling steps in this soak, or narrow the cleanup claim to room-viewer state.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At load-test/connect-disconnect-soak.js, line 139:
<comment>When `--join true` is used, this branch only sends `joinRoom` before disconnecting, so it never allocates a viewer transport or consumer. Run the remaining viewer signaling steps in this soak, or narrow the cleanup claim to room-viewer state.</comment>
<file context>
@@ -0,0 +1,261 @@
+
+ results.connectMs.push(performance.now() - connectStart);
+
+ if (JOIN) {
+ try {
+ const { response, latencyMs } = await ackWithTimeout(
</file context>
| } | ||
| } | ||
|
|
||
| process.exit(0); |
There was a problem hiding this comment.
P2: When connections or joins fail, this command still exits with status 0, so CI or automation cannot detect a failed soak. Exit nonzero when cycles are incomplete or any connect/join error is recorded.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At load-test/connect-disconnect-soak.js, line 258:
<comment>When connections or joins fail, this command still exits with status 0, so CI or automation cannot detect a failed soak. Exit nonzero when cycles are incomplete or any connect/join error is recorded.</comment>
<file context>
@@ -0,0 +1,261 @@
+ }
+ }
+
+ process.exit(0);
+}
+
</file context>




Note: authored by Claude (Anthropic) via Claude Code. Not yet executed against a live backend — results section is a placeholder, not fabricated.
Summary by cubic
Adds a connect/disconnect soak load test to validate that the signaling server releases resources cleanly under sustained connection churn. No server code changes; this is test tooling only.
load-test/connect-disconnect-soak.js) churns connect → optionaljoinRoom→ disconnect cycles, reporting latency percentiles, error counts, and throughput.load-test/results/CONNECT-DISCONNECT-SOAK.mddocuments the run procedure, CLI arguments, and the leak-detection methodology.Written for commit fb09e59. Summary will update on new commits.