SOLR-7370: FSHDFSUtils#recoverFileLease tries to recover the lease every one second after the first four second wait.

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1672379 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Mark Robert Miller 2015-04-09 14:56:26 +00:00
parent d46bed3c32
commit 64ed335455
2 changed files with 4 additions and 1 deletions

View File

@ -98,6 +98,9 @@ Bug Fixes
* SOLR-7066: autoAddReplicas feature has bug when selecting replacement nodes. (Mark Miller)
* SOLR-7370: FSHDFSUtils#recoverFileLease tries to recover the lease every one second after
the first four second wait. (Mark Miller)
Optimizations
----------------------

View File

@ -91,7 +91,7 @@ public class FSHDFSUtils {
// This should be set to how long it'll take for us to timeout against primary datanode if it
// is dead. We set it to 61 seconds, 1 second than the default READ_TIMEOUT in HDFS, the
// default value for DFS_CLIENT_SOCKET_TIMEOUT_KEY.
long subsequentPause = conf.getInt("solr.hdfs.lease.recovery.dfs.timeout", 61 * 1000);
long subsequentPause = TimeUnit.NANOSECONDS.convert(conf.getInt("solr.hdfs.lease.recovery.dfs.timeout", 61 * 1000), TimeUnit.MILLISECONDS);
Method isFileClosedMeth = null;
// whether we need to look for isFileClosed method