Skip to content

Commit

Permalink
Remove all @AwaitsFix in CcrRollingUpgradeIT (#76779)
Browse files Browse the repository at this point in the history
* Remove all @AwaitsFix CcrRollingUpgradeIT

See #76765 and #60054

* Use the wait_for_active_shards adopted from ES 8

* Update CcrRollingUpgradeIT.java

Co-authored-by: Elastic Machine <[email protected]>
  • Loading branch information
arteam and elasticmachine authored Aug 22, 2021
1 parent 0413333 commit 65e8cee
Showing 1 changed file with 3 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
import static org.hamcrest.Matchers.equalTo;

public class CcrRollingUpgradeIT extends AbstractMultiClusterUpgradeTestCase {

public void testUniDirectionalIndexFollowing() throws Exception {
logger.info("clusterName={}, upgradeState={}", clusterName, upgradeState);

Expand Down Expand Up @@ -90,7 +90,6 @@ public void testUniDirectionalIndexFollowing() throws Exception {
}
}

@AwaitsFix(bugUrl = "https://github.com/elastic/elasticsearch/issues/59625")
public void testAutoFollowing() throws Exception {
String leaderIndex1 = "logs-20200101";
String leaderIndex2 = "logs-20200102";
Expand Down Expand Up @@ -209,7 +208,6 @@ public void testAutoFollowing() throws Exception {
}
}

@AwaitsFix(bugUrl = "https://github.com/elastic/elasticsearch/issues/59625")
public void testCannotFollowLeaderInUpgradedCluster() throws Exception {
if (upgradeState != UpgradeState.ALL) {
return;
Expand Down Expand Up @@ -237,7 +235,6 @@ public void testCannotFollowLeaderInUpgradedCluster() throws Exception {
}
}

@AwaitsFix(bugUrl = "https://github.com/elastic/elasticsearch/issues/59625")
public void testBiDirectionalIndexFollowing() throws Exception {
logger.info("clusterName={}, upgradeState={}", clusterName, upgradeState);

Expand Down Expand Up @@ -370,7 +367,8 @@ private static void verifyTotalHitCount(final String index,

private static void stopIndexFollowing(RestClient client, String followerIndex) throws IOException {
pauseIndexFollowing(client, followerIndex);
assertOK(client.performRequest(new Request("POST", "/" + followerIndex + "/_close")));
// https://github.com/elastic/elasticsearch/pull/67158
assertOK(client.performRequest(new Request("POST", "/" + followerIndex + "/_close?wait_for_active_shards=index-setting")));
assertOK(client.performRequest(new Request("POST", "/" + followerIndex + "/_ccr/unfollow")));
}

Expand Down

0 comments on commit 65e8cee

Please sign in to comment.