Repository navigation
dynamic_modules: join async host selection threads in cluster tests - #48439
Merged
agrawroh merged 1 commit intoOct 19, 2026
Merged
Conversation
The cluster integration test module completes asynchronous host selection on a detached std::thread. Every Rust thread runs module code while it exits, because std registers a pthread key destructor in the module, and glibc calls key destructors after the thread-local destructors that keep the module loaded. When a test server shut down while such a thread was still exiting, Envoy unloaded the module under it and the thread crashed in a later test, for example DynamicModuleAsyncTlsIntegrationTest.SessionReuseFollowsLogicalHostnameReverseOrder on the arm64 release job. Keep the join handles and join them when the load balancer is destroyed, like the other Rust test modules do. Envoy destroys every load balancer before it can unload the module. Signed-off-by: Rohit Agrawal <[email protected]>
agrawroh
requested review from
mathetake,
mattklein123 and
wbpcode
as code owners
October 19, 2026 18:27
mathetake-ai
approved these changes
Oct 19, 2026
mathetake
approved these changes
Oct 19, 2026
jwendell
pushed a commit
that referenced
this pull request
Nov 12, 2026
…48439) ## Description This PR fixes a flaky test in the DYM for Cert Selector. --- **Commit Message:** dynamic_modules: join async host selection threads in cluster tests **Risk Level:** Low **Testing:** CI **Docs Changes**: N/A **Release Notes**: N/A Signed-off-by: Rohit Agrawal <[email protected]> Signed-off-by: Ryan Northey <[email protected]>
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.
Description
This PR fixes a flaky test in the DYM for Cert Selector.
Commit Message: dynamic_modules: join async host selection threads in cluster tests
Risk Level: Low
Testing: CI
Docs Changes: N/A
Release Notes: N/A