HDFS-15443. Setting dfs.datanode.max.transfer.threads to a very small value can cause strange failure. Contributed by AMC-team.

(cherry picked from commit c2a17659d1)
This commit is contained in:
Ayush Saxena 2020-08-08 14:33:53 +05:30 committed by S O'Donnell
parent 793ab9acf3
commit d8314fffc0
1 changed files with 3 additions and 0 deletions

View File

@ -188,6 +188,9 @@ class DataXceiverServer implements Runnable {
this.maxXceiverCount = this.maxXceiverCount =
conf.getInt(DFSConfigKeys.DFS_DATANODE_MAX_RECEIVER_THREADS_KEY, conf.getInt(DFSConfigKeys.DFS_DATANODE_MAX_RECEIVER_THREADS_KEY,
DFSConfigKeys.DFS_DATANODE_MAX_RECEIVER_THREADS_DEFAULT); DFSConfigKeys.DFS_DATANODE_MAX_RECEIVER_THREADS_DEFAULT);
Preconditions.checkArgument(this.maxXceiverCount >= 1,
DFSConfigKeys.DFS_DATANODE_MAX_RECEIVER_THREADS_KEY +
" should not be less than 1.");
this.estimateBlockSize = conf.getLongBytes(DFSConfigKeys.DFS_BLOCK_SIZE_KEY, this.estimateBlockSize = conf.getLongBytes(DFSConfigKeys.DFS_BLOCK_SIZE_KEY,
DFSConfigKeys.DFS_BLOCK_SIZE_DEFAULT); DFSConfigKeys.DFS_BLOCK_SIZE_DEFAULT);