HDFS-9842. dfs.datanode.balance.bandwidthPerSec should accept friendly size units. (Contributed by Lin Yiqun)

This commit is contained in:
Arpit Agarwal 2016-02-22 11:34:09 -08:00
parent 3fab88540f
commit a63301a864
3 changed files with 9 additions and 2 deletions

View File

@ -2810,6 +2810,9 @@ Release 2.8.0 - UNRELEASED
HDFS-7452. skip StandbyException log for getCorruptFiles() HDFS-7452. skip StandbyException log for getCorruptFiles()
(Bramha Reddy Battula via vinayakumarb) (Bramha Reddy Battula via vinayakumarb)
HDFS-9842. dfs.datanode.balance.bandwidthPerSec should accept friendly
size units. (Lin Yiqun via Arpit Agarwal)
Release 2.7.3 - UNRELEASED Release 2.7.3 - UNRELEASED
INCOMPATIBLE CHANGES INCOMPATIBLE CHANGES

View File

@ -131,7 +131,7 @@ class DataXceiverServer implements Runnable {
//set up parameter for cluster balancing //set up parameter for cluster balancing
this.balanceThrottler = new BlockBalanceThrottler( this.balanceThrottler = new BlockBalanceThrottler(
conf.getLong(DFSConfigKeys.DFS_DATANODE_BALANCE_BANDWIDTHPERSEC_KEY, conf.getLongBytes(DFSConfigKeys.DFS_DATANODE_BALANCE_BANDWIDTHPERSEC_KEY,
DFSConfigKeys.DFS_DATANODE_BALANCE_BANDWIDTHPERSEC_DEFAULT), DFSConfigKeys.DFS_DATANODE_BALANCE_BANDWIDTHPERSEC_DEFAULT),
conf.getInt(DFSConfigKeys.DFS_DATANODE_BALANCE_MAX_NUM_CONCURRENT_MOVES_KEY, conf.getInt(DFSConfigKeys.DFS_DATANODE_BALANCE_MAX_NUM_CONCURRENT_MOVES_KEY,
DFSConfigKeys.DFS_DATANODE_BALANCE_MAX_NUM_CONCURRENT_MOVES_DEFAULT)); DFSConfigKeys.DFS_DATANODE_BALANCE_MAX_NUM_CONCURRENT_MOVES_DEFAULT));

View File

@ -815,7 +815,11 @@
<description> <description>
Specifies the maximum amount of bandwidth that each datanode Specifies the maximum amount of bandwidth that each datanode
can utilize for the balancing purpose in term of can utilize for the balancing purpose in term of
the number of bytes per second. the number of bytes per second. You can use the following
suffix (case insensitive):
k(kilo), m(mega), g(giga), t(tera), p(peta), e(exa)to specify the size
(such as 128k, 512m, 1g, etc.).
Or provide complete size in bytes (such as 134217728 for 128 MB).
</description> </description>
</property> </property>