Skip to content

Commit b4e852a

Browse files
authored
[TEST] Wait for no pending operations on the index shard (#118244)
This fixes testRetryPointInTime which on teardown is looking to assert that the operations in the translog and in the lucene index are the same. Previously we didn't wait for the translog operations to be applied. This changes `assertConsistentHistoryInLuceneIndex` to wait for the pending operations in the translog to be applied. Fixes #117116
1 parent 6bb0799 commit b4e852a

File tree

2 files changed

+1
-3
lines changed

2 files changed

+1
-3
lines changed

muted-tests.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -157,9 +157,6 @@ tests:
157157
- class: org.elasticsearch.xpack.test.rest.XPackRestIT
158158
method: test {p0=snapshot/10_basic/Create a source only snapshot and then restore it}
159159
issue: https://github.com/elastic/elasticsearch/issues/117295
160-
- class: org.elasticsearch.xpack.searchablesnapshots.RetrySearchIntegTests
161-
method: testRetryPointInTime
162-
issue: https://github.com/elastic/elasticsearch/issues/117116
163160
- class: org.elasticsearch.xpack.inference.DefaultEndPointsIT
164161
method: testInferDeploysDefaultElser
165162
issue: https://github.com/elastic/elasticsearch/issues/114913

test/framework/src/main/java/org/elasticsearch/snapshots/AbstractSnapshotIntegTestCase.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,7 @@ protected Collection<Class<? extends Plugin>> nodePlugins() {
128128

129129
@After
130130
public void assertConsistentHistoryInLuceneIndex() throws Exception {
131+
internalCluster().beforeIndexDeletion();
131132
internalCluster().assertConsistentHistoryBetweenTranslogAndLuceneIndex();
132133
}
133134

0 commit comments

Comments
 (0)