Skip to content

Replace OldIndexBackwardsCompatibilityIT#testOldClusterStates with a full cluster restart qa test #25370

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

martijnvg
Copy link
Member

OldIndexBackwardsCompatibilityIT#testOldClusterStates tested whether global and index metadata could be read from data directory. I think this can also be tested in full cluster qa test that checks cluster state via cluster state api, this would also verify that the upgraded nodes were able to read the global and index state files successfully.

Relates to #24939

@martijnvg martijnvg added review >test Issues or PRs that are addressing/adding tests v6.0.0 labels Jun 22, 2017
@@ -352,4 +352,10 @@ public boolean isCompatible(Version left, Version right) {
return result;
}

private static final Version VERSION_5_1_0_UNRELEASED = Version.fromString("5.1.0");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think we need the constant.

@@ -352,4 +352,10 @@ public boolean isCompatible(Version left, Version right) {
return result;
}

private static final Version VERSION_5_1_0_UNRELEASED = Version.fromString("5.1.0");

public void testUnreleasedVersion() {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know it didn't have a comment before but I imagine it'd be nice to add a comment now. Something like "This exists because 5.1.0 was never released due to a mistake in the release process. This verifies that we never declare the version as "released" accidentally. It would never pass qa tests later on, but those come very far in the build and this is quick to check now."

}

public void testAllVersionsTested() throws Exception {
SortedSet<String> expectedVersions = new TreeSet<>();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For posterity: this is handled by the gradle logic that scrapes the version file and a test in VersionUtilsTests that verifies that the gradle logic and VersionUtils line up.

…ith a full cluster restart qa test

OldIndexBackwardsCompatibilityIT#testOldClusterStates tested whether global and index metadata could be read from data directory,
 this can also be tested in full cluster qa test that checks cluster state via api.

 Relates to elastic#24939
@martijnvg martijnvg force-pushed the bwc_replace_testOldClusterStates_test branch from d283ee5 to 9c511bc Compare June 23, 2017 07:54
@martijnvg martijnvg merged commit 9c511bc into elastic:master Jun 23, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
>test Issues or PRs that are addressing/adding tests v6.0.0-beta1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants