From e9a3932dbce9bbc3d9e216a5c239aadfddef930a Mon Sep 17 00:00:00 2001 From: Nhat Nguyen Date: Tue, 19 Dec 2017 11:17:57 -0500 Subject: [PATCH] Fix incorrectly assign local checkpoint from max_seqno Relates #27837 --- .../indices/recovery/PeerRecoveryTargetService.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/main/java/org/elasticsearch/indices/recovery/PeerRecoveryTargetService.java b/core/src/main/java/org/elasticsearch/indices/recovery/PeerRecoveryTargetService.java index 0c20d708360..c25315a23b5 100644 --- a/core/src/main/java/org/elasticsearch/indices/recovery/PeerRecoveryTargetService.java +++ b/core/src/main/java/org/elasticsearch/indices/recovery/PeerRecoveryTargetService.java @@ -356,7 +356,7 @@ public class PeerRecoveryTargetService extends AbstractComponent implements Inde final long globalCheckpoint = Translog.readGlobalCheckpoint(recoveryTarget.translogLocation()); final Tuple seqNoStats = recoveryTarget.store().loadSeqNoInfo(); long maxSeqNo = seqNoStats.v1(); - long localCheckpoint = seqNoStats.v1(); + long localCheckpoint = seqNoStats.v2(); if (maxSeqNo <= globalCheckpoint) { assert localCheckpoint <= globalCheckpoint; /*