-
Notifications
You must be signed in to change notification settings - Fork 13k
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
[ISSUE #11655]fix invalid usage of ProporityQueue in ConfigChangePluginManger #11668
Conversation
…ngePluginManager
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## develop #11668 +/- ##
==========================================
Coverage 66.77% 66.77%
- Complexity 8825 8832 +7
==========================================
Files 1238 1238
Lines 40534 40538 +4
Branches 4297 4297
==========================================
+ Hits 27065 27069 +4
- Misses 11526 11530 +4
+ Partials 1943 1939 -4
... and 4 files with indirect coverage changes Continue to review full report in Codecov by Sentry.
|
config/src/main/java/com/alibaba/nacos/config/server/aspect/ConfigChangeAspect.java
Show resolved
Hide resolved
return false; | ||
} | ||
} | ||
return true; |
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.
can replaced with Lambda
@@ -83,8 +84,10 @@ private static void loadConfigChangeServices() { | |||
// map the relationship of pointcut and plugin service | |||
addPluginServiceByPointCut(each); |
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.
check service enabled here ,if not enabled,do not add to the final list , and logs should be printed for what we loaded from service loader and what we ignored if service not enabled
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.
If you load here, it won't be able to fetch dynamically updated config like AuthConfigs?
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.
If you load here, it won't be able to fetch dynamically updated config like AuthConfigs?
ok, you are right, just ignore this comment
ConfigChangePointCutTypes configChangePointCutType) { | ||
PriorityQueue<ConfigChangePluginService> pluginServicePriorityQueue = ConfigChangePluginManager | ||
.findPluginServiceQueueByPointcut(configChangePointCutType); | ||
List<ConfigChangePluginService> pluginServicePriorityQueue = ConfigChangePluginManager |
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.
pluginServicePriorityQueue should be renamed to pluginServicePriorityList
…ngePluginManger (alibaba#11668) * [ISSUE alibaba#11655]fix invalid usage of ProporityQueue in ConfigChangePluginManager * add UT for config change plugin * for checkstyle * for checkstyle
Please do not create a Pull Request without creating an issue first.
What is the purpose of the change
Fixed an issue #11655 fix invalid usage of ProporityQueue in ConfigChangePluginMaanger
Brief changelog
XX
Verifying this change
XXXX
Follow this checklist to help us incorporate your contribution quickly and easily:
[ISSUE #123] Fix UnknownException when host config not exist
. Each commit in the pull request should have a meaningful subject line and body.mvn -B clean package apache-rat:check findbugs:findbugs -Dmaven.test.skip=true
to make sure basic checks pass. Runmvn clean install -DskipITs
to make sure unit-test pass. Runmvn clean test-compile failsafe:integration-test
to make sure integration-test pass.