-
Notifications
You must be signed in to change notification settings - Fork 63
Bump controller-runtime to v0.14.1 and k8s API to v0.26.1 #1060
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
Conversation
Before merging this PR, we should do a smoke test against the Che Operator next to ensure the updated k8s API version does not cause issues. |
Code looks good to me 😎. I had experimented recently with upgrading the controller-runtime to v0.14.1 and am familiar with the API changes that were required (
I'm currently spinning up a cluster to test this out before approving this PR. |
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.
The mock client pkg/library/flatten/internal/testutil/
needs to be modified so that the get
function has the opts ...client.GetOption
parameter.
I also compiled DWO (..even with the issues in the test files somehow? Maybe go doesn't care if there's compilation issues in the test files) and created + subscribed to the catalog source, and then deployed che:next with chectl and opened up the Che-Website workspace and things worked fine. Though I will repeat this process once the small final changes are made to this PR :) |
Update: * sigs.k8s.io/controller-runtime to v0.14.1 * k8s.io/api (et al.) to v0.26.1 This update matches versions for the Kubernetes API and controller runtime with devfile/api. Signed-off-by: Angel Misevski <[email protected]>
Signed-off-by: Angel Misevski <[email protected]>
* Replace corev1.Handler with corev1.LifecycleHandler or ProbeHandler as required * Replace k8s.io/apimachinery/pkg/util/clock with k8s.io/utils/clock Signed-off-by: Angel Misevski <[email protected]>
The functionality from operator-utils is now available in controller-runtime, making the additional dependency unnecessary as its functions just wrap controller-runtime The operator-utils dependency makes updating controller-runtime difficult as operator-utils itself depends on k8s.io/api and controller-runtime. Signed-off-by: Angel Misevski <[email protected]>
Signed-off-by: Angel Misevski <[email protected]>
9112acd
to
84e9c2c
Compare
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## main #1060 +/- ##
==========================================
- Coverage 51.41% 51.37% -0.05%
==========================================
Files 76 76
Lines 6595 6595
==========================================
- Hits 3391 3388 -3
- Misses 2938 2940 +2
- Partials 266 267 +1
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
ping @AObuchow waiting on approval |
Going to approve this since everything worked with Che when I last tested this PR even when the tests were broken (since the tests weren't part of the actual DWO image) |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: amisevsk, AObuchow The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
What does this PR do?
Updates core dependencies:
* sigs.k8s.io/controller-runtime to v0.14.1
* k8s.io/api (et al.) to v0.26.1
Notable changes in the update:
corev1.Handler
is replaced withcorev1.LifecycleHandler
andcorev1.ProbeHandler
k8s.io/apimachinery/pkg/util/clock
is replaced withk8s.io/utils/clock
github.com/go-logr/logr/testing
is deprecated in favor ofmygithub.libinneed.workers.dev/go-logr/logr/testr
The update also ran into issues around
github.com/redhat-cop/operator-utils
, the latest version of which depends on k8s APIv0.25.0
and controller-runtimev0.13.0
. Since our usages of this package have been integrated into controller-runtime, the dependency is dropped in favor of these methods (latest versions of operator-utils just wrap the controller-runtime equivalents).What issues does this PR fix or reference?
Closes #1059
Is it tested? How?
N/A
PR Checklist
/test v8-devworkspace-operator-e2e, v8-che-happy-path
to trigger)v8-devworkspace-operator-e2e
: DevWorkspace e2e testv8-che-happy-path
: Happy path for verification integration with Che