-
Notifications
You must be signed in to change notification settings - Fork 588
HDDS-815. Rename Ozone/HDDS config keys prefixed with 'dfs' #6187
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
tanvipenumudy
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.
Thank you @sarvekshayr for the patch.
Could you please rebase your patch on top of the latest master?
...n-test/src/test/java/org/apache/hadoop/ozone/client/rpc/TestContainerStateMachineStream.java
Outdated
Show resolved
Hide resolved
adoroszlai
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 @sarvekshayr for working on this. When changing config keys, we have to consider backwards compatibility:
Existing clusters may already be configured using the old keys. If we simply change the keys, those configs will no longer work after upgrade. Cluster will suddenly start to use the default settings.
The way to keep old settings work is by deprecating the old key, which is usually done here:
ozone/hadoop-hdds/common/src/main/java/org/apache/hadoop/hdds/conf/OzoneConfiguration.java
Lines 313 to 328 in 60bcdaf
| private static void addDeprecatedKeys() { | |
| Configuration.addDeprecations(new DeprecationDelta[]{ | |
| new DeprecationDelta("ozone.datanode.pipeline.limit", | |
| ScmConfigKeys.OZONE_DATANODE_PIPELINE_LIMIT), | |
| new DeprecationDelta(HDDS_DATANODE_RATIS_PREFIX_KEY + "." | |
| + RaftServerConfigKeys.PREFIX + "." + "rpcslowness.timeout", | |
| HDDS_DATANODE_RATIS_PREFIX_KEY + "." | |
| + RaftServerConfigKeys.PREFIX + "." + "rpc.slowness.timeout"), | |
| new DeprecationDelta("dfs.datanode.keytab.file", | |
| DFSConfigKeysLegacy.DFS_DATANODE_KERBEROS_KEYTAB_FILE_KEY), | |
| new DeprecationDelta("ozone.scm.chunk.layout", | |
| ScmConfigKeys.OZONE_SCM_CONTAINER_LAYOUT_KEY), | |
| new DeprecationDelta("hdds.datanode.replication.work.dir", | |
| OZONE_CONTAINER_COPY_WORKDIR) | |
| }); | |
| } |
Also, please wait for clean CI run in your fork before opening PRs.
hadoop-hdds/common/src/main/java/org/apache/hadoop/ozone/OzoneConfigKeys.java
Show resolved
Hide resolved
...n-test/src/test/java/org/apache/hadoop/ozone/client/rpc/TestContainerStateMachineStream.java
Outdated
Show resolved
Hide resolved
|
Thanks @sarvekshayr for updating the patch. There are a few config keys with Also, Java constants for default values of the renamed config keys still use the old ozone/hadoop-hdds/common/src/main/java/org/apache/hadoop/ozone/OzoneConfigKeys.java Lines 79 to 81 in 2cbabcc
|
|
Thank you for the review @adoroszlai ! I'll rename the remaining ones as well. I'll create a sub-task to do the same in order to reduce the size of this patch. |
|
To clarify my comment about separating changes: it's not just about the size of the patch itself. Renaming config keys is a relatively small change, focused on a few files, but it must be well tested to ensure compatibility. On the other hand, renaming constants is a massive, but simple change, affecting ~50 files in this case. Yet, regular CI checks are enough as a test; it should be fine as long as code compiles and checkstyle is happy. This part of the change is likely to cause merge conflicts for other PRs. |
|
Thank you for the clarification. I'll make the changes as indicated. |
|
Updated HDDS-815 to reflect the current set of config keys to be renamed (6 keys no longer exist, 15 new keys). The original task description mentioned using "either HDDS or Ozone" as prefix. I have updated it to use
|
What changes were proposed in this pull request?
Renaming config keys and its corresponding variable name prefixed with 'dfs' to 'ozone'.
What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-815
How was this patch tested?
Patch was tested by running the test classes of the modified files.