Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Use a static FastThreadLocal in CombinerExecutor instead of a instance field #5082

Merged
merged 1 commit into from
Jan 29, 2024

Conversation

vietj
Copy link
Member

@vietj vietj commented Jan 29, 2024

The CombinerExecutor class creates an instance of FastThreadLocal for each combiner executor leading to an increase of the InternalThreadLocalMap index. Consequently each thread local map of FastThreadLocalThread will get a new map sized accordingly, leading to an eventual memory leak.

Use a static FastThreadLocal in CombinerExecutor instead of a instance field, the data structure stored in this thread local map keeps track of the CombinerExecutor running in order to allow interleaved execution of CombinerExecutor post tasks without interfering each other. The structure is optimized for the most frequent case.

Fixes https://access.redhat.com/security/cve/CVE-2024-1023

… each combiner executor leading to an increase of the InternalThreadLocalMap index. Consequently each thread local map of FastThreadLocalThread will get a new map sized accordingly, leading to an eventual memory leak.

Use a static FastThreadLocal in CombinerExecutor instead of a instance field, the data structure stored in this thread local map keeps track of the CombinerExecutor running in order to allow interleaved execution of CombinerExecutor post tasks without interfering each other. The structure is optimized for the most frequent case.
@vietj vietj added this to the 4.4.7 milestone Jan 29, 2024
@vietj vietj merged commit dd6f643 into 4.4 Jan 29, 2024
7 checks passed
@vietj vietj deleted the use-static-fast-thread-local-in-combiner-executor-4.4 branch January 29, 2024 15:46
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant