HDFS-9911. TestDataNodeLifeline Fails intermittently. Contributed by Yiqun Lin

(cherry picked from commit a95639068c)
This commit is contained in:
Anu Engineer 2016-12-16 09:46:21 -08:00 committed by Eric Payne
parent 4703f5d20b
commit d20dc8691e
1 changed files with 2 additions and 1 deletions

View File

@ -1083,7 +1083,7 @@ static class Scheduler {
volatile long nextHeartbeatTime = monotonicNow();
@VisibleForTesting
volatile long nextLifelineTime = monotonicNow();
volatile long nextLifelineTime;
@VisibleForTesting
volatile long lastBlockReportTime = monotonicNow();
@ -1111,6 +1111,7 @@ static class Scheduler {
this.lifelineIntervalMs = lifelineIntervalMs;
this.blockReportIntervalMs = blockReportIntervalMs;
this.slowPeersReportIntervalMs = slowPeersReportIntervalMs;
scheduleNextLifeline(nextHeartbeatTime);
}
// This is useful to make sure NN gets Heartbeat before Blockreport