Skip to content

[bwc] Add bugfix3 project #126880

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

brianseeders
Copy link
Contributor

There are now 3 "bugfix" projects from a BWC standpoint, which causes the following error:

./gradlew --quiet --console=plain tagVersions --release=8.18.0 --tag-version=TransportVersion:8840002 --tag-version=IndexVersion:8525000
...
        | A problem occurred evaluating project ':distribution:bwc'.
        | > Failed to apply plugin 'elasticsearch.internal-distribution-bwc-setup'.
        |    > Cannot add extension with name 'bwcSetup', as there is an extension already registered with that name.

Because there are two bugfix2 projects. This adds a 3rd one. I'm not sure if this is the best approach here.

Finalizing the 8.18.0 release is blocked until this is solved.

@brianseeders brianseeders added >non-issue >test Issues or PRs that are addressing/adding tests :Delivery/Build Build or test infrastructure v9.1.0 labels Apr 15, 2025
@brianseeders brianseeders requested a review from a team April 15, 2025 21:17
@brianseeders brianseeders requested a review from a team as a code owner April 15, 2025 21:17
@elasticsearchmachine elasticsearchmachine added the Team:Delivery Meta label for Delivery team label Apr 15, 2025
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-delivery (Team:Delivery)

@jozala
Copy link
Contributor

jozala commented Apr 16, 2025

How about removing the 7.17 from branches.json instead?
The outcome would be then:

8.17.6=UnreleasedVersionInfo[version=8.17.6, branch=8.17, gradleProjectPath=:distribution:bwc:maintenance],
8.18.1=UnreleasedVersionInfo[version=8.18.1, branch=8.18, gradleProjectPath=:distribution:bwc:bugfix2],
8.19.0=UnreleasedVersionInfo[version=8.19.0, branch=8.x, gradleProjectPath=:distribution:bwc:minor],
9.0.1=UnreleasedVersionInfo[version=9.0.1, branch=9.0, gradleProjectPath=:distribution:bwc:bugfix],
9.1.0=UnreleasedVersionInfo[version=9.1.0, branch=main, gradleProjectPath=:distribution]

From the BwC tests I believe it makes sense because we do not test the compatibility for upgrades between 7 and 9.
Version 7.17 would be still tested in BwC tests on 8.x branches.

I am not sure what might be the other side-effects of removing 7.17 from branches.json. I know we still maintain this branch, so some tools might depend on that. Can you advise on that?

@jozala
Copy link
Contributor

jozala commented Apr 16, 2025

Alternatively, it would be possible to filter the featureFreezeBranches to exclude 7.17 from the logic of BwC but leave it in branches.json:

        // Now handle all the feature freeze branches
        List<String> featureFreezeBranches = developmentBranches.stream()
            .filter(b -> Pattern.matches("[0-9]+\\.[0-9]+", b))
            .filter(b -> currentVersion.getMajor() - Version.fromString(b, Version.Mode.RELAXED).getMajor() <= 1) // I've added this line
            .sorted(reverseOrder(comparing(s -> Version.fromString(s, Version.Mode.RELAXED))))
            .toList();

It gives the same result as removing 7.17 from branches.json:

8.17.6=UnreleasedVersionInfo[version=8.17.6, branch=8.17, gradleProjectPath=:distribution:bwc:maintenance],
8.18.1=UnreleasedVersionInfo[version=8.18.1, branch=8.18, gradleProjectPath=:distribution:bwc:bugfix2],
8.19.0=UnreleasedVersionInfo[version=8.19.0, branch=8.x, gradleProjectPath=:distribution:bwc:minor],
9.0.1=UnreleasedVersionInfo[version=9.0.1, branch=9.0, gradleProjectPath=:distribution:bwc:bugfix],
9.1.0=UnreleasedVersionInfo[version=9.1.0, branch=main, gradleProjectPath=:distribution]

It also have no side-effects and should be compatible with other branches so we can backport it to 8.x branches.
What do you think?
I will prepare a separate PR with that so we can decide which path to go.

EDIT:
PR prepared with alternative approach here: #126895

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Delivery/Build Build or test infrastructure >non-issue Team:Delivery Meta label for Delivery team >test Issues or PRs that are addressing/adding tests v9.1.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants