-
Notifications
You must be signed in to change notification settings - Fork 444
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
all: upgrade minimum supported Go release to 1.22 #2850
Conversation
BenchmarksBenchmark execution time: 2024-09-09 17:01:02 Comparing candidate commit 333ddfe in PR branch Found 0 performance improvements and 0 performance regressions! Performance is the same for 58 metrics, 1 unstable metrics. |
With Go 1.23 released on 2024-08-13, we drop support for Go 1.21. This means Go 1.22 is now our minimum supported Go release. Update our CI files to reflect our current supported Go versions, and remove pre-Go 1.22 workarounds.
58d3603
to
6a96206
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe there are small changes to do here
We don't need them any more.
Done, thanks for the review @eliottness |
What does this PR do?
With Go 1.23 released on 2024-08-13, we drop support for Go 1.21. This
means Go 1.22 is now our minimum supported Go release. Update our CI
files to reflect our current supported Go versions, and remove pre-Go
1.22 workarounds.
In addition to the CI bumps, this PR changes/fixes a few things related to the upgrade:
rand
from the tracer, now that we can depend onmath/rand/v2
.slices
in the appsec package.TestWrapHandlerWithResourceNameNoRace
got a new data race. Specifically,by bumping our
go.mod
to 1.22, we get the new 1.22 ServeMux behavior internally.The 1.22 ServeMux modifies the Request, introducing a race with all the goroutines
accessing/modifying the request concurrently. Fix it by giving each goroutine its own
request. I verified that the test still catches the intended bug by reverting the fix from
contrib/net/http: Copy span options and resource name to avoid data race #2204 and verifying that the test fails.
Motivation
Follow our declared Go support policy.
Reviewer's Checklist
Unsure? Have a question? Request a review!