Running org.elasticsearch.xpack.slm.SLMSnapshotBlockingIntegTests in a loop I can easily reproduce failing tests from race conditions around aborting a snapshot that is in state INIT.
Example failure:
REPRODUCE WITH: ./gradlew 'null' --tests "org.elasticsearch.xpack.slm.SLMSnapshotBlockingIntegTests.testSnapshotInProgress" -Dtests.seed=3F6218BBB4942CD0 -Dtests.locale=es-AR -Dtests.timezone=America/Phoenix
org.elasticsearch.snapshots.ConcurrentSnapshotExecutionException: [my-repo:snap-aotuscactpiiyvbypiydca/0px1dM0eS7icvTYMxcM1Hw] Another concurrent operation moved repo generation to [ 0] but this delete assumed generation [-1]
at __randomizedtesting.SeedInfo.seed([3F6218BBB4942CD0:86DD16153A98DDDE]:0)
at org.elasticsearch.repositories.blobstore.BlobStoreRepository.deleteSnapshot(BlobStoreRepository.java:494)
at org.elasticsearch.snapshots.SnapshotsService.lambda$deleteSnapshotFromRepository$15(SnapshotsService.java:1243)
at org.elasticsearch.action.ActionListener$1.onResponse(ActionListener.java:63)
at org.elasticsearch.repositories.blobstore.BlobStoreRepository.getRepositoryData(BlobStoreRepository.java:1118)
at org.elasticsearch.snapshots.SnapshotsService.lambda$deleteSnapshotFromRepository$17(SnapshotsService.java:1243)
at org.elasticsearch.action.ActionRunnable$2.doRun(ActionRunnable.java:73)
at org.elasticsearch.common.util.concurrent.ThreadContext$ContextPreservingAbstractRunnable.doRun(ThreadContext.java:691)
at org.elasticsearch.common.util.concurrent.AbstractRunnable.run(AbstractRunnable.java:37)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.lang.Thread.run(Thread.java:830)
Fix incoming in #54765
Running
org.elasticsearch.xpack.slm.SLMSnapshotBlockingIntegTestsin a loop I can easily reproduce failing tests from race conditions around aborting a snapshot that is in stateINIT.Example failure:
Fix incoming in #54765