Improve finalizer handling #2039
Labels
kind/bug
Categorizes issue or PR as related to a bug.
kind/release-blocking
Issues or PRs that need to be closed before the next CAPV release
lifecycle/active
Indicates that an issue or PR is actively being worked on by a contributor.
/kind bug
I think we have to improve our finalizer handling in CAPV.
The ideal behavior in Reconcile is the following:
I recently had a PR to fix this everywhere in core CAPI: kubernetes-sigs/cluster-api#8949
Reasoning:
An easy example how this should look like can be found here: https://github.com/sbueringer/cluster-api/blob/cef1cf1d9312088a785c520f49970b1c609ab9ad/internal/controllers/cluster/cluster_controller.go#L145-L158
Note: it's important that the defer patch is done in a way that the finalizer is actually written
Environment:
kubectl version
):/etc/os-release
):The text was updated successfully, but these errors were encountered: