Skip to content

org.elasticsearch.upgrades.ClusterFeatureMigrationIT fails intermittently #114330

@ChrisHegarty

Description

@ChrisHegarty

Reproduce with:

./gradlew ":qa:rolling-upgrade:v8.16.0#bwcTest" -Dtests.class="org.elasticsearch.upgrades.ClusterFeatureMigrationIT" -Dtests.method="testClusterFeatureMigration {upgradedNodes=1}"

fails with:

ClusterFeatureMigrationIT > testClusterFeatureMigration {upgradedNodes=1} FAILED
    java.lang.AssertionError
        at __randomizedtesting.SeedInfo.seed([DB7C7EA7CA82F8CD:FB3214C70CD760E]:0)
        at org.elasticsearch.upgrades.ParameterizedRollingUpgradeTestCase.oldClusterHasFeature(ParameterizedRollingUpgradeTestCase.java:143)
        at org.elasticsearch.upgrades.ParameterizedRollingUpgradeTestCase.oldClusterHasFeature(ParameterizedRollingUpgradeTestCase.java:148)
        at org.elasticsearch.upgrades.ClusterFeatureMigrationIT.checkMigrationVersion(ClusterFeatureMigrationIT.java:34)

The test appears to hit an assert when trying to determine whether or not the old cluster has a feature.

  protected static boolean oldClusterHasFeature(String featureId) {
      assert oldClusterTestFeatureService != null;    <<<<<<<<<<<< HERE
      return oldClusterTestFeatureService.clusterHasFeature(featureId);
  }

I believe that the intermittency of the failure comes from the randomisation of the execution order of the three @Before methods in ParameterizedRollingUpgradeTestCase. Are these order dependent? kinda looks like they are; or at least extractOldClusterFeatures needs to be run before upgradeNode.

Metadata

Metadata

Assignees

No one assigned

    Labels

    :Core/Infra/CoreCore issues without another label>test-failureTriaged test failures from CITeam:Core/InfraMeta label for core/infra teamlow-riskAn open issue or test failure that is a low risk to future releases

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions