connpool: Fix crash in pool removal if the cluster was already deleted#17522
Merged
ggreenway merged 1 commit intoenvoyproxy:mainfrom Jul 28, 2021
Merged
connpool: Fix crash in pool removal if the cluster was already deleted#17522ggreenway merged 1 commit intoenvoyproxy:mainfrom
ggreenway merged 1 commit intoenvoyproxy:mainfrom
Conversation
The idle callback was incorrectly going through the ThreadLocalClusterManagerImpl::ClusterEntry to reach the ThreadLocalClusterManager. The pool is owned by the ThreadLocalClusterManager, not by the ClusterEntry, so the reference to the ClusterEntry could be dangling, resulting in a crash. fixes commit envoyproxy#17403 Signed-off-by: Greg Greenway <ggreenway@apple.com>
Member
Author
|
The changes to the test are just reverting (logically, after naming changes) removal of those bits in #17403 . I don't know why I removed that, but it was a necessary part of the test, and would have caught this. |
mattklein123
approved these changes
Jul 28, 2021
Member
mattklein123
left a comment
There was a problem hiding this comment.
Makes sense to me, thanks!
alyssawilk
approved these changes
Jul 28, 2021
Contributor
alyssawilk
left a comment
There was a problem hiding this comment.
LGTM though if possible to integration test this (even if race prone) please do as at least a follow-up. I think having more e2e coverage of this would be fantastic.
baojr
added a commit
to baojr/envoy
that referenced
this pull request
Jul 29, 2021
…bridge-stream * upstream/main: (140 commits) quiche: remove google quic support (envoyproxy#17465) runtime: removing envoy.reloadable_features.check_ocsp_policy (envoyproxy#17524) upstream: not trying to do HTTP/3 where not configured (envoyproxy#17454) api: Remove confusing line about auto-generation (envoyproxy#17536) v2: removing bootstrap (envoyproxy#17523) connpool: Fix crash in pool removal if the cluster was already deleted (envoyproxy#17522) Enhance the comments clearly (envoyproxy#17517) mysql proxy: connection attributes parsing (envoyproxy#17209) [ci] fix false positive CVE scan from node (envoyproxy#17510) Fixing Envoy Mobile factory strings (envoyproxy#17509) http3: validating codec (envoyproxy#17452) quic: add QUIC upstream stream reset error stats (envoyproxy#17496) thrift proxy: move UpstreamRequest into its own file (envoyproxy#17498) docs: Fixed FaultDelay docs. (envoyproxy#17495) updates links to jaegertracing-plugin.tar.gz (envoyproxy#17497) http: make custom inline headers bootstrap configurable (envoyproxy#17330) deps: update yaml-cpp to latest master (envoyproxy#17489) improving tracer coverage (envoyproxy#17493) Increase buffer size of `Win32RedirectRecords` (envoyproxy#17471) ext_proc: Fix problem with buffered body mode with empty or no body (envoyproxy#17430) ... Signed-off-by: Garrett Bourg <bourg@squareup.com>
leyao-daily
pushed a commit
to leyao-daily/envoy
that referenced
this pull request
Sep 30, 2021
envoyproxy#17522) The idle callback was incorrectly going through the ThreadLocalClusterManagerImpl::ClusterEntry to reach the ThreadLocalClusterManager. The pool is owned by the ThreadLocalClusterManager, not by the ClusterEntry, so the reference to the ClusterEntry could be dangling, resulting in a crash. fixes commit envoyproxy#17403 Signed-off-by: Greg Greenway <ggreenway@apple.com>
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.
Signed-off-by: Greg Greenway ggreenway@apple.com
Commit Message: The idle callback was incorrectly going through the
ThreadLocalClusterManagerImpl::ClusterEntry to reach the
ThreadLocalClusterManager. The pool is owned by the
ThreadLocalClusterManager, not by the ClusterEntry, so the reference
to the ClusterEntry could be dangling, resulting in a crash.
fixes commit #17403
Additional Description:
Risk Level: Low
Testing: Restored test that was incorrectly removed
Docs Changes: None
Release Notes: None
Platform Specific Features:
[Optional Runtime guard:]
[Optional Fixes #Issue]
[Optional Deprecated:]
[Optional API Considerations:]