Repository navigation
server: test that quiesce waits for an open connection before the server is freed - #6471
Conversation
Synthena Initial Review — Initial diff check passed (awaiting device run) (
|
|
READY to land on this head. Test-only: a host test that quiesce() waits for an open connection's thread before the server is freed, plus its test import; no server or serving code changes, so tokens and the served path are unchanged. All PR checks pass on this head.
|
…ver is freed quiesce() stops the accept loop and then waits on open_connections, with a 5 s panic as its bound. No test ever kept a connection open past the accept loop, so nothing showed that the wait happens at all. The new test in health_quiesce_test.zig opens a bare connection, waits for open_connections to rise, closes it from another thread after 200 ms, and asserts open_connections is zero when quiesce returns. Every wait in it is bounded. It sits in its own file, registered in root.zig beside health_test.zig, so health_test.zig stays under 600 lines; health_test.zig only gains pub on the five declarations the new file reads. quiesce itself is unchanged.
acf1478 to
28ddb07
Compare
|
Thank you @BadAd84. This is merged into main with your commits under your own name, so you're listed as a TensorFold contributor. It ships in the next release, credited to you in the changelog and the release notes. |
What this changes
quiesce() in health_test.zig just stops the accept loop and then waits on open_connections (with a 5s panic as its bound). No test ever kept a connection open past the accept loop, so nothing showed the wait happens at all.
This adds one test: it opens a bare connection, waits for open_connections to go up, closes it from another thread after 200ms and asserts open_connections is 0 when quiesce returns.
quiesce itself is unchanged (and still has its 5s bound) and every wait in the new test is bounded too.
atc overlap --json: clean against every overlapping open PR it reached (Prefill on a GB10, decode on a Mac: long prompts for Qwen3.8-27B handed over ConnectX (#1594, step 2b) #2648, hip ranks: every byte after the key proof crosses the link in sealed records #3075, logit_bias: token biases and -100 bans on each row's draw for Qwen CUDA, Qwen3.5-2B Metal and Nemotron Parse HIP #3146, glm cuda: warm turns under TF_GLM_REQUEST_STARTS=1, every message start a cut, DFlash2's ring kept alike on every rank (#3109) #3147, lane host: --stall-seconds marks a stalled engine unavailable, --stall-exit restarts it #3165, server: forget one conversation's kept states (POST /v1/imprint/forget) #3226). The full scan stopped at its PR limit, so cuda: opt-in complete-round attribution for speculative decoding #5263, which also edits health_test.zig, was checked on its own with--pulls 5263: complete, clean.Checks on this head
python3 tools/zig/lean_check.py, on the base and on this head: 88 and 88, 0 new (all inherited).zig build test-cuda-host569/569 steps, 6352 passed, 0 failed, 41 skipped.zig build test-rows-host170/170 passed.zig fmt --check zig/andgit diff --checkclean. With quiesce's wait loop removed, test-cuda-host fails exactly this test (expected 0, found 1).tools/ci_local.py --mode changedran in full and every step passed except test-host-a, where page-disk tests in core, which this change doesn't touch, hit their wall-clock disk deadline on a loaded host (a different test on each run).Receipt
n/a: test-only. No engine, server or inference code changes; health_test.zig only gains
pubon five fixtures the new file reads.Checklist