Skip to content

Commit

Permalink
Bump k8s.io/* deps to v0.31 & controller-runtime to v0.19 (#1185)
Browse files Browse the repository at this point in the history
* Upgrade k8s dependencies to `v0.31.0` and controller-runtime to `v0.19.0`, adapting code for breaking changes

* Regenerate code and manifests after updating k8s dependencies
  • Loading branch information
sujeet01 authored Dec 19, 2024
1 parent f6f5680 commit bf1d999
Show file tree
Hide file tree
Showing 195 changed files with 1,835 additions and 5,107 deletions.
9 changes: 5 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ BUCKETBROKER_IMG ?= bucketbroker:latest
IRICTL_BUCKET_IMG ?= irictl-bucket:latest

# ENVTEST_K8S_VERSION refers to the version of kubebuilder assets to be downloaded by envtest binary.
ENVTEST_K8S_VERSION = 1.30.3
ENVTEST_K8S_VERSION = 1.31

# Docker image name for the mkdocs based local development setup
IMAGE=ironcore/documentation
Expand Down Expand Up @@ -145,7 +145,7 @@ clean-docs: ## Remove all local mkdocs Docker images (cleanup).
docker container prune --force --filter "label=project=ironcore_documentation"

.PHONY: test
test: manifests generate fmt vet test-only ## Run tests.
test: generate manifests fmt vet test-only ## Run tests.

.PHONY: test-only
test-only: envtest ## Run *only* the tests - no generation, linting etc.
Expand Down Expand Up @@ -360,13 +360,14 @@ GOLANGCI_LINT ?= $(LOCALBIN)/golangci-lint
## Tool Versions
KUSTOMIZE_VERSION ?= v5.1.1
VGOPATH_VERSION ?= v0.1.3
CONTROLLER_TOOLS_VERSION ?= v0.15.0
CONTROLLER_TOOLS_VERSION ?= v0.16.0
GEN_CRD_API_REFERENCE_DOCS_VERSION ?= v0.3.0
ADDLICENSE_VERSION ?= v1.1.1
PROTOC_GEN_GOGO_VERSION ?= v1.3.2
GOIMPORTS_VERSION ?= v0.26.0
GOLANGCI_LINT_VERSION ?= v1.62.2
OPENAPI_EXTRACTOR_VERSION ?= v0.1.9
SETUP_ENVTEST_VERSION ?= release-0.19

KUSTOMIZE_INSTALL_SCRIPT ?= "https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh"
.PHONY: kustomize
Expand Down Expand Up @@ -404,7 +405,7 @@ $(VGOPATH): $(LOCALBIN)
.PHONY: envtest
envtest: $(ENVTEST) ## Download envtest-setup locally if necessary.
$(ENVTEST): $(LOCALBIN)
test -s $(LOCALBIN)/setup-envtest || GOBIN=$(LOCALBIN) go install sigs.k8s.io/controller-runtime/tools/setup-envtest@latest
test -s $(LOCALBIN)/setup-envtest || GOBIN=$(LOCALBIN) go install sigs.k8s.io/controller-runtime/tools/setup-envtest@$(SETUP_ENVTEST_VERSION)

.PHONY: openapi-extractor
openapi-extractor: $(OPENAPI_EXTRACTOR) ## Download openapi-extractor locally if necessary.
Expand Down
9 changes: 4 additions & 5 deletions broker/machinebroker/networks/networks.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ type Manager struct {

cluster cluster.Cluster

queue workqueue.RateLimitingInterface
queue workqueue.TypedRateLimitingInterface[string]

waitersByProviderIDMu sync.Mutex
waitersByProviderID map[string]*waiter
Expand All @@ -36,7 +36,7 @@ type Manager struct {
func NewManager(cluster cluster.Cluster) *Manager {
return &Manager{
cluster: cluster,
queue: workqueue.NewRateLimitingQueue(workqueue.DefaultControllerRateLimiter()),
queue: workqueue.NewTypedRateLimitingQueue(workqueue.DefaultTypedControllerRateLimiter[string]()),
waitersByProviderID: make(map[string]*waiter),
}
}
Expand Down Expand Up @@ -144,13 +144,12 @@ func (e *Manager) doWork(ctx context.Context, providerID string) (*networkingv1a
}

func (e *Manager) processNextWorkItem(ctx context.Context) bool {
uncastProviderID, quit := e.queue.Get()
providerID, quit := e.queue.Get()
if quit {
return false
}
defer e.queue.Done(uncastProviderID)
defer e.queue.Done(providerID)

providerID := uncastProviderID.(string)
network, err := e.doWork(ctx, providerID)
e.emit(providerID, network, err)
e.queue.Forget(providerID)
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions client-go/applyconfigurations/compute/v1alpha1/efivar.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 8 additions & 2 deletions client-go/applyconfigurations/compute/v1alpha1/machine.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 8 additions & 2 deletions client-go/applyconfigurations/compute/v1alpha1/machineclass.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 8 additions & 2 deletions client-go/applyconfigurations/compute/v1alpha1/machinepool.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions client-go/applyconfigurations/compute/v1alpha1/machinespec.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit bf1d999

Please sign in to comment.