Skip to content

Commit cd9e971

Browse files
surendralilhoreahussein
authored andcommitted
HDFS-14630. Configuration.getTimeDurationHelper() should not log time unit warning in info log. Contributed by hemanthboyina.
1 parent 1c49805 commit cd9e971

File tree

2 files changed

+16
-9
lines changed

2 files changed

+16
-9
lines changed

hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/conf/Configuration.java

100644100755
Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1885,8 +1885,6 @@ private long getTimeDurationHelper(String name, String vStr,
18851885
vStr = StringUtils.toLowerCase(vStr);
18861886
ParsedTimeDuration vUnit = ParsedTimeDuration.unitFor(vStr);
18871887
if (null == vUnit) {
1888-
logDeprecation("No unit for " + name + "(" + vStr + ") assuming " +
1889-
defaultUnit);
18901888
vUnit = ParsedTimeDuration.unitFor(defaultUnit);
18911889
} else {
18921890
vStr = vStr.substring(0, vStr.lastIndexOf(vUnit.suffix()));

hadoop-hdfs-project/hadoop-hdfs/src/main/resources/hdfs-default.xml

100644100755
Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -756,7 +756,8 @@
756756
<value>0s</value>
757757
<description>
758758
Delay for first block report in seconds. Support multiple time unit
759-
suffix(case insensitive), as described in dfs.heartbeat.interval.
759+
suffix(case insensitive), as described in dfs.heartbeat.interval.If
760+
no time unit is specified then seconds is assumed
760761
</description>
761762
</property>
762763

@@ -801,7 +802,8 @@
801802
<description>Interval in seconds for Datanode to scan data directories and
802803
reconcile the difference between blocks in memory and on the disk.
803804
Support multiple time unit suffix(case insensitive), as described
804-
in dfs.heartbeat.interval.
805+
in dfs.heartbeat.interval.If no time unit is specified then seconds
806+
is assumed.
805807
</description>
806808
</property>
807809

@@ -842,6 +844,7 @@
842844
ms(millis), s(sec), m(min), h(hour), d(day)
843845
to specify the time (such as 2s, 2m, 1h, etc.).
844846
Or provide complete number in seconds (such as 30 for 30 seconds).
847+
If no time unit is specified then seconds is assumed.
845848
</description>
846849
</property>
847850

@@ -1051,6 +1054,7 @@
10511054
<description>Namenode periodicity in seconds to check if
10521055
decommission or maintenance is complete. Support multiple time unit
10531056
suffix(case insensitive), as described in dfs.heartbeat.interval.
1057+
If no time unit is specified then seconds is assumed.
10541058
</description>
10551059
</property>
10561060

@@ -1181,7 +1185,8 @@
11811185
<description>
11821186
The number of seconds between two periodic checkpoints.
11831187
Support multiple time unit suffix(case insensitive), as described
1184-
in dfs.heartbeat.interval.
1188+
in dfs.heartbeat.interval.If no time unit is specified then seconds
1189+
is assumed.
11851190
</description>
11861191
</property>
11871192

@@ -1200,7 +1205,8 @@
12001205
<description>The SecondaryNameNode and CheckpointNode will poll the NameNode
12011206
every 'dfs.namenode.checkpoint.check.period' seconds to query the number
12021207
of uncheckpointed transactions. Support multiple time unit suffix(case insensitive),
1203-
as described in dfs.heartbeat.interval.
1208+
as described in dfs.heartbeat.interval.If no time unit is specified then
1209+
seconds is assumed.
12041210
</description>
12051211
</property>
12061212

@@ -1636,7 +1642,8 @@
16361642
The notification is sent by a datanode when it is being shutdown
16371643
using the shutdownDatanode admin command with the upgrade option.
16381644
Support multiple time unit suffix(case insensitive), as described
1639-
in dfs.heartbeat.interval.
1645+
in dfs.heartbeat.interval.If no time unit is specified then seconds
1646+
is assumed.
16401647
</description>
16411648
</property>
16421649

@@ -1705,7 +1712,8 @@
17051712
often the logs are rolled. Note that failover triggers a log roll
17061713
so the StandbyNode will be up to date before it becomes active.
17071714
Support multiple time unit suffix(case insensitive), as described
1708-
in dfs.heartbeat.interval.
1715+
in dfs.heartbeat.interval.If no time unit is specified then seconds
1716+
is assumed.
17091717
</description>
17101718
</property>
17111719

@@ -3413,7 +3421,8 @@
34133421
datanode is not yet registered with the namenode. This wait time
34143422
reduces initial request failures after datanode restart.
34153423
Support multiple time unit suffix(case insensitive), as described
3416-
in dfs.heartbeat.interval.
3424+
in dfs.heartbeat.interval.If no time unit is specified then seconds
3425+
is assumed.
34173426
</description>
34183427
</property>
34193428

0 commit comments

Comments
 (0)