Update controller-runtime to v0.14.4 #78
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
controller-runtime deprecated the envtest/printer package in v0.14.0. They don't needed anymore since they upgraded to ginko v2. In order to keep the scope contained, I just copied the code we needed, it's quite simple. This allow us to maintain the same version of ginko while bumping controller-runtime.
The fake client provided by controller-runtime was updated to allow for field selectors in List operations. This requires to define the index prior to its use. Since the Job controller uses ".metadata.controller" for a List query, we now set this index in the tests client.
kubernetes-sigs/controller-runtime#2025
Why is this needed
It allows consumers of rufio as a module to start using new versions of controller-runtime. Technically we didn't need to upgrade controller-runtime, just stop using the deprecated package. But I thought it wouldn't hurt, specially once we decide to start using go 1.19, since this comes with versions of k8s.io packages that already support to 1.19.
How Has This Been Tested?
Not tested. Looking at the release notes, it seems like there aren't any behavior changes, so as long as unit tests pass, it should be a transparent drop-in change.
How are existing users impacted? What migration steps/scripts do we need?
No upgrade/migration needed.
Checklist:
I have: