File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed
core/src/test/java/org/elasticsearch/index/shard Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change 8080import org .elasticsearch .index .mapper .ParsedDocument ;
8181import org .elasticsearch .index .mapper .SeqNoFieldMapper ;
8282import org .elasticsearch .index .mapper .SourceToParse ;
83+ import org .elasticsearch .index .seqno .SequenceNumbers ;
8384import org .elasticsearch .index .seqno .SequenceNumbersService ;
8485import org .elasticsearch .index .snapshots .IndexShardSnapshotStatus ;
8586import org .elasticsearch .index .store .Store ;
@@ -738,6 +739,11 @@ public void onFailure(Exception e) {
738739
739740 public void testConcurrentTermIncreaseOnReplicaShard () throws BrokenBarrierException , InterruptedException , IOException {
740741 final IndexShard indexShard = newStartedShard (false );
742+ /*
743+ * When a shard recovers from a primary, it will advance its global checkpoint. We simulate that here; since we are not performing
744+ * any operations, we initialize to no operations performed as the local checkpoint on this shard carries the same value.
745+ */
746+ indexShard .updateGlobalCheckpointOnReplica (SequenceNumbersService .NO_OPS_PERFORMED );
741747
742748 final CyclicBarrier barrier = new CyclicBarrier (3 );
743749 final CountDownLatch latch = new CountDownLatch (2 );
You can’t perform that action at this time.
0 commit comments