HBASE-18216 [AMv2] Workaround for HBASE-18152, corrupt procedure WAL;

ADDENDUM

Forgot this change found testing.
This commit is contained in:
Michael Stack 2017-06-13 21:58:48 -07:00
parent 1eb2f2593d
commit 16a5a9db3e
1 changed files with 2 additions and 2 deletions

View File

@ -483,7 +483,7 @@ public class ProcedureWALFormatReader {
*/ */
private static boolean isIncreasing(ProcedureProtos.Procedure current, private static boolean isIncreasing(ProcedureProtos.Procedure current,
ProcedureProtos.Procedure candidate) { ProcedureProtos.Procedure candidate) {
boolean increasing = current.getStackIdCount() < candidate.getStackIdCount() && boolean increasing = current.getStackIdCount() <= candidate.getStackIdCount() &&
current.getLastUpdate() <= candidate.getLastUpdate(); current.getLastUpdate() <= candidate.getLastUpdate();
if (!increasing) { if (!increasing) {
LOG.warn("NOT INCREASING! current=" + current + ", candidate=" + candidate); LOG.warn("NOT INCREASING! current=" + current + ", candidate=" + candidate);
@ -868,4 +868,4 @@ public class ProcedureWALFormatReader {
return (int)(Procedure.getProcIdHashCode(procId) % procedureMap.length); return (int)(Procedure.getProcIdHashCode(procId) % procedureMap.length);
} }
} }
} }