-
Notifications
You must be signed in to change notification settings - Fork 26.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix: AbstractCacheManager destroy Framework's executorService when shutdown #14091
base: 3.2
Are you sure you want to change the base?
Conversation
Introduce disposable resource register mechanism. Follows "who creates, who destroys" rule.
gen by mvn eclipse:eclipse
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@chickenlj PTAL
Quality Gate passedIssues Measures |
The change itself in the refactoring patch is right. The "who creates, who destroys" design introduced is indeed impressive, but I think it's not so demanded in this scenario in which all operations are restricted inside one instance, it can be more useful when need to release or close resources across different components. |
@chickenlj Thank you for your comments. As mentioned, the change is right, is the PR ready to merged back? |
From the description of this PR, it fixes the following issue |
Functional change: This PR is valuable only when CacheManager's lifecycle is different with Framework. |
Introduce disposable resource register mechanism. Follows "who creates, who destroys" rule.
What is the purpose of the change
Protect framework-executor from being destroyed by AbstractCacheManager.
Brief changelog
Introduce disposable resource register mechanism, simplify disposable#destroy implementation.
Verifying this change
Checklist