Skip to content

Commit

Permalink
Force update operation primary term in replication checkout post fail…
Browse files Browse the repository at this point in the history
…over

Signed-off-by: bansvaru <[email protected]>
  • Loading branch information
linuxpi committed Jan 23, 2024
1 parent b0eab75 commit 77d94ac
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1697,7 +1697,8 @@ ReplicationCheckpoint computeReplicationCheckpoint(SegmentInfos segmentInfos) th
}
final ReplicationCheckpoint latestReplicationCheckpoint = getLatestReplicationCheckpoint();
if (latestReplicationCheckpoint.getSegmentInfosVersion() == segmentInfos.getVersion()
&& latestReplicationCheckpoint.getSegmentsGen() == segmentInfos.getGeneration()) {
&& latestReplicationCheckpoint.getSegmentsGen() == segmentInfos.getGeneration()
&& latestReplicationCheckpoint.getPrimaryTerm() == getOperationPrimaryTerm()) {
return latestReplicationCheckpoint;
}
final Map<String, StoreFileMetadata> metadataMap = store.getSegmentMetadataMap(segmentInfos);
Expand Down

0 comments on commit 77d94ac

Please sign in to comment.