Repository navigation
test(agent): retry once a GET whose idle connection Caddy closed during the switch - #437
Merged
Merged
Conversation
… connection Temporary stress run included, to classify the rare failures of the switch test on the CI runner. Signed-off-by: samuel mbabhazi <[email protected]>
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 57 minutes. View limit details
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. |
…ion during the switch Caddy closes idle keep-alive connections at each configuration change. A request sent on one at that instant fails unserved, and HTTP lets an idempotent request be sent again (RFC 9112, 9.3.1). The switch test now retries that one case, counts it, and still fails on any other error. Each failure says whether its connection was a reused idle one. Signed-off-by: samuel mbabhazi <[email protected]>
samuelmbabhazi
marked this pull request as ready for review
November 23, 2026 14:35
This was referenced Nov 23, 2026
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.
TestRealCaddySwitchesUnderLoadWithoutAFailedRequestfailed once in about 30 CI runs, on #427, which does not touch the agent: 3 of 8,612 requests failed during the switch.What the failure was
write: connection reset by peer,read: connection reset by peer,EOF. An upstream that could not be reached would have given a 502 instead.Trying to reproduce it
compose.ymlpins: 6 runs of the test, then a stress of 20 switches under 32 clients (16,949 requests). Not one failure.What changed
loadtraces each request's connection (httptrace), and knows whether it was a reused idle one.Follow-up, not in this pull request
ApplyRoutechanges Caddy's configuration twice per switch: the route, then the plain hosts. One load per switch would halve the moments at which idle connections are closed.How it was tested
go vet -tags integrationandgolangci-lint: 0 issues.Security considerations
Test only.