diff --git a/hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/store/wal/WALProcedureStore.java b/hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/store/wal/WALProcedureStore.java index d14e1bf0ff3..0c8cfd24403 100644 --- a/hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/store/wal/WALProcedureStore.java +++ b/hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/store/wal/WALProcedureStore.java @@ -359,7 +359,16 @@ public class WALProcedureStore extends ProcedureStoreBase { lock.lock(); try { LOG.trace("Starting WAL Procedure Store lease recovery"); + boolean afterFirstAttempt = false; while (isRunning()) { + // Don't sleep before first attempt + if (afterFirstAttempt) { + LOG.trace("Sleep {} ms after first lease recovery attempt.", + waitBeforeRoll); + Threads.sleepWithoutInterrupt(waitBeforeRoll); + } else { + afterFirstAttempt = true; + } FileStatus[] oldLogs = getLogFiles(); // Get Log-MaxID and recover lease on old logs try {