File tree Expand file tree Collapse file tree 1 file changed +2
-8
lines changed
server/src/test/java/org/elasticsearch/index/seqno Expand file tree Collapse file tree 1 file changed +2
-8
lines changed Original file line number Diff line number Diff line change @@ -102,14 +102,8 @@ private static Set<String> ids(Set<AllocationId> allocationIds) {
102102 }
103103
104104 private void updateLocalCheckpoint (final ReplicationTracker tracker , final String allocationId , final long localCheckpoint ) {
105- final long globalCheckpoint = tracker .getGlobalCheckpoint ();
106- updatedGlobalCheckpoint .set (globalCheckpoint );
107105 tracker .updateLocalCheckpoint (allocationId , localCheckpoint );
108- if (globalCheckpoint == tracker .getGlobalCheckpoint ()) {
109- assertThat (updatedGlobalCheckpoint .get (), equalTo (globalCheckpoint ));
110- } else {
111- assertThat (updatedGlobalCheckpoint .get (), equalTo (tracker .getGlobalCheckpoint ()));
112- }
106+ assertThat (updatedGlobalCheckpoint .get (), equalTo (tracker .getGlobalCheckpoint ()));
113107 }
114108
115109 public void testGlobalCheckpointUpdate () {
@@ -433,7 +427,7 @@ public void testWaitForAllocationIdToBeInSync() throws Exception {
433427 thread .join ();
434428 }
435429
436- private AtomicLong updatedGlobalCheckpoint = new AtomicLong ();
430+ private AtomicLong updatedGlobalCheckpoint = new AtomicLong (UNASSIGNED_SEQ_NO );
437431
438432 private ReplicationTracker newTracker (final AllocationId allocationId ) {
439433 return new ReplicationTracker (
You can’t perform that action at this time.
0 commit comments