Skip to content

Commit

Permalink
Upgrade Go to 1.24 (#7023)
Browse files Browse the repository at this point in the history
* No changes to source code.
* The antrea/codegen image was updated to use Go 1.24. No changes in
  generated files.
* golangci-lint was updated to the latest available version (v1.64.5).
* Metrics doc was regenerated.

Fixes #7022

Signed-off-by: Antonin Bas <antonin.bas@broadcom.com>
  • Loading branch information
antoninbas authored Feb 25, 2025
1 parent fa26350 commit ecd36d4
Show file tree
Hide file tree
Showing 7 changed files with 21 additions and 8 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ GIT_HOOKS := $(shell find hack/git_client_side_hooks -type f -print)
DOCKER_NETWORK ?= default
TRIVY_TARGET_IMAGE ?=

GOLANGCI_LINT_VERSION := v1.60.3
GOLANGCI_LINT_VERSION := v1.64.5
GOLANGCI_LINT_BINDIR := $(CURDIR)/.golangci-bin
GOLANGCI_LINT_BIN := $(GOLANGCI_LINT_BINDIR)/$(GOLANGCI_LINT_VERSION)/golangci-lint

Expand Down
1 change: 1 addition & 0 deletions build/images/codegen/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ Here is the table of codegen images that have been uploaded:

| Tag | Change |
| :------------------------ | ----------------------------------------------------------------------------- |
| kubernetes-1.31.1-build.2 | Upgraded Go to v1.24 |
| kubernetes-1.31.1-build.1 | Upgraded controller-gen to v0.16.3 |
| kubernetes-1.31.1-build.0 | Upgraded go.uber.org/mock/mockgen to v0.5.0 |
| kubernetes-1.31.1 | Upgraded K8s libraries to v1.31.1, ubuntu to 24.04 |
Expand Down
2 changes: 1 addition & 1 deletion build/images/deps/go-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.23
1.24
18 changes: 15 additions & 3 deletions docs/prometheus-integration.md
Original file line number Diff line number Diff line change
Expand Up @@ -475,6 +475,10 @@ due to a non-default GODEBUG=gocachetest=... setting. Sourced from
The number of non-default behaviors executed by the cmd/go package
due to a non-default GODEBUG=gocacheverify=... setting. Sourced from
/godebug/non-default-behavior/gocacheverify:events
- **go_godebug_non_default_behavior_gotestjsonbuildtext_events_total:**
The number of non-default behaviors executed by the cmd/go package due
to a non-default GODEBUG=gotestjsonbuildtext=... setting. Sourced from
/godebug/non-default-behavior/gotestjsonbuildtext:events
- **go_godebug_non_default_behavior_gotypesalias_events_total:**
The number of non-default behaviors executed by the go/types package
due to a non-default GODEBUG=gotypesalias=... setting. Sourced from
Expand Down Expand Up @@ -527,6 +531,14 @@ due to a non-default GODEBUG=panicnil=... setting. Sourced from
The number of non-default behaviors executed by the math/rand package
due to a non-default GODEBUG=randautoseed=... setting. Sourced from
/godebug/non-default-behavior/randautoseed:events
- **go_godebug_non_default_behavior_randseednop_events_total:** The
number of non-default behaviors executed by the math/rand package
due to a non-default GODEBUG=randseednop=... setting. Sourced from
/godebug/non-default-behavior/randseednop:events
- **go_godebug_non_default_behavior_rsa1024min_events_total:** The
number of non-default behaviors executed by the crypto/rsa package
due to a non-default GODEBUG=rsa1024min=... setting. Sourced from
/godebug/non-default-behavior/rsa1024min:events
- **go_godebug_non_default_behavior_tarinsecurepath_events_total:**
The number of non-default behaviors executed by the archive/tar package
due to a non-default GODEBUG=tarinsecurepath=... setting. Sourced from
Expand Down Expand Up @@ -567,10 +579,10 @@ due to a non-default GODEBUG=x509keypairleaf=... setting. Sourced from
The number of non-default behaviors executed by the crypto/x509 package
due to a non-default GODEBUG=x509negativeserial=... setting. Sourced from
/godebug/non-default-behavior/x509negativeserial:events
- **go_godebug_non_default_behavior_x509sha1_events_total:** The
- **go_godebug_non_default_behavior_x509rsacrt_events_total:** The
number of non-default behaviors executed by the crypto/x509 package
due to a non-default GODEBUG=x509sha1=... setting. Sourced from
/godebug/non-default-behavior/x509sha1:events
due to a non-default GODEBUG=x509rsacrt=... setting. Sourced from
/godebug/non-default-behavior/x509rsacrt:events
- **go_godebug_non_default_behavior_x509usefallbackroots_events_total:**
The number of non-default behaviors executed by the crypto/x509 package
due to a non-default GODEBUG=x509usefallbackroots=... setting. Sourced from
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module antrea.io/antrea

go 1.23.0
go 1.24.0

require (
antrea.io/libOpenflow v0.15.0
Expand Down
2 changes: 1 addition & 1 deletion hack/update-codegen.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ function echoerr {
}

ANTREA_ROOT="$( cd "$( dirname "${BASH_SOURCE[0]}" )/../" && pwd )"
IMAGE_NAME="antrea/codegen:kubernetes-1.31.1-build.1"
IMAGE_NAME="antrea/codegen:kubernetes-1.31.1-build.2"

# We will use git clone to make a working copy of the repository into a
# temporary directory. This requires that all changes have been committed
Expand Down
2 changes: 1 addition & 1 deletion multicluster/hack/update-codegen.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ function echoerr {
}

ANTREA_ROOT="$( cd "$( dirname "${BASH_SOURCE[0]}" )/../../" && pwd )"
IMAGE_NAME="antrea/codegen:kubernetes-1.31.1-build.1"
IMAGE_NAME="antrea/codegen:kubernetes-1.31.1-build.2"

# We will use git clone to make a working copy of the repository into a
# temporary directory. This requires that all changes have been committed
Expand Down

0 comments on commit ecd36d4

Please sign in to comment.