ndimiduk commented on a change in pull request #3139:
URL: https://github.com/apache/hbase/pull/3139#discussion_r625367579
##########
File path:
hbase-server/src/main/java/org/apache/hadoop/hbase/master/normalizer/SimpleRegionNormalizer.java
##########
@@ -101,11 +106,21 @@ public void onConfigurationChange(Configuration conf) {
setConf(conf);
}
- private static int parseMinRegionCount(final Configuration conf) {
- final int parsedValue = conf.getInt(MIN_REGION_COUNT_KEY,
DEFAULT_MIN_REGION_COUNT);
+ private static int parseMergeMinRegionCount(final Configuration conf) {
+ String parsedStringValue = conf.get(MERGE_MIN_REGION_COUNT_KEY);
Review comment:
I think we need to keep the old config in hbase-defaults.xml and add the
new config there as well.
```
modified hbase-common/src/main/resources/hbase-default.xml
@@ -41,6 +41,8 @@ possible configurations would overwhelm and obscure the
important.
<configuration>
<!--Configs you will likely change are listed here at the top of the file.
-->
+ <property><name>foo</name><value>42</value><description>deprecated; see
'bar'</description></property>
+ <property><name>bar</name><value>42</value></property>
<property >
<name>hbase.tmp.dir</name>
<value>${java.io.tmpdir}/hbase-${user.name}</value>
---
| Welcome to JShell -- Version 11.0.10
| For an introduction type: /help intro
jshell> import org.apache.hadoop.conf.Configuration
jshell> import org.apache.hadoop.hbase.HBaseConfiguration
jshell> Configuration c = HBaseConfiguration.create()
c ==> Configuration: core-default.xml, core-site.xml, h ... efault.xml,
hbase-site.xml
jshell> c.get("foo")
$4 ==> "42"
jshell> c.get("bar")
$5 ==> "42"
jshell> Configuration.addDeprecation("foo", "bar")
jshell> c.get("foo")
2021-05-03T14:03:00,038 INFO [main] Configuration.deprecation: foo is
deprecated. Instead, use bar
$7 ==> "42"
jshell> c.get("bar")
$8 ==> "42"
jshell> c.set("foo", "99")
jshell> c.get("foo")
$10 ==> "99"
jshell> c.get("bar")
$11 ==> "99"
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]