-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
[Discuss] Improve the process around backporting and version checks #8070
Comments
@msfroh this is definitely very painful experience, I have though about it a lot, and the solution you've proposed does make sense. There are two other options I would like to bring in:
|
One caveat here is that the version check update PR on main will fail its gradle check until the backport PR is merged.
The thing I don't like about this approach is there is no forcing function to do the forward port. You can develop and release your feature and "forget" to do the forward port and it might not be missed until the release of the next major version (which can be a year or more). With the backport process if you forget to do the backport then your feature doesn't get shipped. @msfroh @reta I have also thought about this a lot and every option seems to have downsides. I'm going to suggest one more option (which might be the worst one yet):
|
@andrross isn't this just delaying the problem for longer, rather we should fix the versions in main as soon as backport PR is merged in 2.x branch. It would be difficult to chase the owners then and maintainers would need to take care unless we are planning to automate it.
+1 on automating this by adding relevant labels |
@shwetathareja Yes (I did say it was a bad idea after all :) ). It does delay the problem, but also isolates the breakages to a single point in time on a single PR. Let's use the upcoming 2.9 release as an example. When the 2.9 release branch is cut, there would be a PR on main that would change it to start running the bwc tests against the new 2.9 branch. The tests would not pass in that PR until all the places that require the version guard to be changed from 3.0 to 2.9 are updated. This should be fairly straightforward (just search for What is still unsatisfying about the automation approach is that it doesn't prevent build breakages due to backporting a feature. At best it can just reduce the time window in which things are broken. |
Would introducing a version label that shows intent help? We would annotate the feature as |
@dblock How is the existing |
I am saying that "2.x_intended" would be in code, not in a GitHub issue/pr/workflow. |
Describe the bug
When people backport an API change to the 2.x branch, the backward-compatibility tests on the main branch are broken until the version check in main is updated.
To Reproduce
Steps to reproduce the behavior:
if (out.getVersion().onOrAfter(Version.V_3_0_0))
main
branch.2.x
branch that changes the version check to the upcoming 2.x release (e.g.V_2_9_0
).main
are broken.main
that changes the version check to the upcoming 2.x release, to match the2.x
branch.The mixed cluster tests fail because the
main
/ 3.0 nodes don't send the new stuff to the2.x
/ 2.9.0 nodes, but the 2.9.0 nodes are expecting the new stuff.Changing the order of PRs wouldn't help. If you change the version check on
main
toV_2_9_0
before the code is backported to2.x
, then the tests would fail becausemain
/ 3.0 sends the2.x
/ 2.9.0 nodes the new stuff before they know what to do with it.In a perfect world, we would be able to atomically merge the backport PR and the updated version check on
main
in a single operation. Alas the world is imperfect and we can't change multiple branches in a single operation.Proposed solution
The best solution that I've been able to think of is:
a. Confirm that the version check update PR exists (and is just making the correct version check change) before merging the backport PR.
b. Commit to merging the version check update PR really soon after merging the backport PR.
This is a terrible solution that relies on good intentions and asks humans to implement a transaction. I hate this solution and would love to hear better suggestions.
Note: The version check update PR will have failing mixed cluster tests until the backport PR has been merged. We could suggest that maintainers merge the backport PR, retry Gradle Check on the version check update PR, confirm that it now passes, then merge the version check update PR. That would leave other people's Gradle Checks broken for ~35 minutes. Of course, this also assumes no flaky test failures. Hahahaha!
Additional context
See e.g:
The text was updated successfully, but these errors were encountered: