[
https://issues.apache.org/jira/browse/HDFS-10219?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15214123#comment-15214123
]
Lin Yiqun commented on HDFS-10219:
----------------------------------
I'm not sure for that if this change will has effect on unit tests, because it
seems many tests has used this config. I'm glad to work for this, upload a
simple patch from me. In addition, I found this config was missing in
hdfs-default.xml. I have added in my patch.Pending jenkins.
> Change the default value for dfs.namenode.replication.pending.timeout-sec
> from -1 to 300
> ----------------------------------------------------------------------------------------
>
> Key: HDFS-10219
> URL: https://issues.apache.org/jira/browse/HDFS-10219
> Project: Hadoop HDFS
> Issue Type: Improvement
> Reporter: Akira AJISAKA
> Priority: Minor
>
> The default value for "dfs.namenode.replication.pending.timeout-sec"
> ({{DFS_NAMENODE_REPLICATION_PENDING_TIMEOUT_SEC_DEFAULT}}) is -1, but the
> timeout is 5 minutes by default.
> {code:title=BlockManager.java}
> pendingReplications = new PendingReplicationBlocks(conf.getInt(
> DFSConfigKeys.DFS_NAMENODE_REPLICATION_PENDING_TIMEOUT_SEC_KEY,
> DFSConfigKeys.DFS_NAMENODE_REPLICATION_PENDING_TIMEOUT_SEC_DEFAULT) *
> 1000L);
> {code}
> {code:title=PendingReplicationBlocks.java}
> private long timeout = 5 * 60 * 1000;
> private final static long DEFAULT_RECHECK_INTERVAL = 5 * 60 * 1000;
> PendingReplicationBlocks(long timeoutPeriod) {
> if ( timeoutPeriod > 0 ) {
> this.timeout = timeoutPeriod;
> }
> pendingReplications = new HashMap<>();
> timedOutItems = new ArrayList<>();
> }
> {code}
> I'm thinking we can change
> {{DFS_NAMENODE_REPLICATION_PENDING_TIMEOUT_SEC_DEFAULT}} from -1 to 300 for
> improving readability.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)