test(gateway): Fix CI flakiness - #73
Merged
Merged
Conversation
…eadiness CI flaked with the gateway never discovering worker0's models: routing to only0 returned NOT_FOUND, round-robin saw only worker1, and the SHM fan-out to worker0 hit DEADLINE_EXCEEDED. The mocks started asynchronously (start! is non-blocking) on close-then-rebind free ports, and the gateway runs its first synchronous discovery as soon as serve_gateway returns, so on a slow CI runner the first probe could hit a half-started mock, after which calls to that worker hung for the rest of the test. The mocks now bind OS-assigned ephemeral ports (no free-port race) and the start helper blocks until a ServerReady round trip succeeds, so the gateway's first discovery always probes a live, warm worker. The readiness poll also pre-compiles the mock's handler paths, removing the cold-first-request stall. Verified 6/6 standalone runs of test_gateway.jl and a full 711/711 gateway suite.
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.
No description provided.