diff --git a/server/src/internalClusterTest/java/org/elasticsearch/snapshots/ConcurrentSnapshotsIT.java b/server/src/internalClusterTest/java/org/elasticsearch/snapshots/ConcurrentSnapshotsIT.java index 538548fc9f0..8f71eadf0b2 100644 --- a/server/src/internalClusterTest/java/org/elasticsearch/snapshots/ConcurrentSnapshotsIT.java +++ b/server/src/internalClusterTest/java/org/elasticsearch/snapshots/ConcurrentSnapshotsIT.java @@ -784,17 +784,21 @@ public class ConcurrentSnapshotsIT extends AbstractSnapshotIntegTestCase { blockNodeOnAnyFiles(blockedRepoName, masterNode); final ActionFuture deleteFuture = startDeleteFromNonMasterClient(blockedRepoName, "*"); waitForBlock(masterNode, blockedRepoName, TimeValue.timeValueSeconds(30L)); + awaitNDeletionsInProgress(1); final ActionFuture createBlockedSnapshot = startFullSnapshotFromNonMasterClient(blockedRepoName, "queued-snapshot"); + awaitNSnapshotsInProgress(1); final long generation = getRepositoryData(repoName).getGenId(); blockNodeOnAnyFiles(repoName, masterNode); final ActionFuture snapshotThree = startFullSnapshotFromNonMasterClient(repoName, "snapshot-three"); waitForBlock(masterNode, repoName, TimeValue.timeValueSeconds(30L)); + awaitNSnapshotsInProgress(2); corruptIndexN(repoPath, generation); final ActionFuture snapshotFour = startFullSnapshotFromNonMasterClient(repoName, "snapshot-four"); + awaitNSnapshotsInProgress(3); internalCluster().stopCurrentMasterNode(); ensureStableCluster(3);