-
Notifications
You must be signed in to change notification settings - Fork 3.4k
HBASE-29526 Dynamic configuration not working for coprocessor #7514
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
Conversation
This comment has been minimized.
This comment has been minimized.
6eee0d3 to
c8a4c3e
Compare
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
c8a4c3e to
fe1f2af
Compare
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
taklwu
left a comment
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.
you are right about the updateConfiguration() has been updated so that getConf() has been updated. thanks for spotting this bug.
| Set<String> currentlyLoaded = coprocessorHost.getCoprocessorClassNames(); | ||
|
|
||
| // Get coprocessor class names from configuration | ||
| Set<String> configuredClasses = new HashSet<>(); | ||
| for (String key : configurationKey) { | ||
| String[] classes = conf.getStrings(key); | ||
| if (classes != null) { | ||
| for (String className : classes) { | ||
| // Handle the className|priority|path format | ||
| String[] classNameToken = className.split("\\|"); | ||
| String actualClassName = classNameToken[0].trim(); | ||
| if (!Strings.isNullOrEmpty(actualClassName)) { | ||
| configuredClasses.add(actualClassName); | ||
| } | ||
| } | ||
| } | ||
| } |
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.
this made me rethink about the configuration change detection cannot handle path reload, and even if we can detect changes for classname and priority.
So, can you update a note/comment in the function checkConfigurationChange, that priority and path changes are not supported with the same classname once it's loaded?
| !conf.getBoolean(CoprocessorHost.COPROCESSORS_ENABLED_CONF_KEY, | ||
| CoprocessorHost.DEFAULT_COPROCESSORS_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.
maybe we should move this COPROCESSORS_ENABLED_CONF_KEY check to the top of checkConfigurationChange
…rocessor enabled check to top
|
🎊 +1 overall
This message was automatically generated. |
|
🎊 +1 overall
This message was automatically generated. |
taklwu
left a comment
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.
thanks for fixing the bug!
|
@Jaehui-Lee can you open PRs for branch-3, branch-2, branch-2.6 as well ? |
|
I opened PRs for branch-3, branch-2, branch-2.6
Thanks! |
https://issues.apache.org/jira/browse/HBASE-29526