This repository has been archived by the owner on Oct 10, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 192
TKR Status Controller: Cluster UpdatesAvailable #2223
Merged
imikushin
merged 7 commits into
vmware-tanzu:main
from
imikushin:cluster-updates-available
Apr 29, 2022
Merged
TKR Status Controller: Cluster UpdatesAvailable #2223
imikushin
merged 7 commits into
vmware-tanzu:main
from
imikushin:cluster-updates-available
Apr 29, 2022
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Intersect resolved TKRs for the controlPlane and machineDeployments. Also, do not use status conditions for OSImage label selector calculation, because these conditions are only applicable to TKR. Signed-off-by: Ivan Mikushin <imikushin@vmware.com>
imikushin
commented
Apr 24, 2022
Implement the TKR Status Controller that: - labels available TKRs and OSImages based on their status conditions, - calculates Cluster status condition UpdatesAvailable for individual Clusters. Also, make sure we return the TKR version as available update if the update TKR has the same K8s version. TKR version can be used directly in Cluster.spec.topology.version field. The resolver webhook will use the TKR as though it was already resolved (if it satisfies the TKR and OSImage selectors, of course). Signed-off-by: Ivan Mikushin <imikushin@vmware.com>
imikushin
force-pushed
the
cluster-updates-available
branch
from
April 24, 2022 22:20
086e426
to
99b6958
Compare
Enqueue clusters updating to the TKR we're being notified about (vs clusters using the TKR): If case we have a certain Kubernetes version (or the TKR version directly) in the UpdatesAvailable message for a cluster, and the TKR is deactivated, we want to re-calculate the UpdatesAvailable message for the cluster. Signed-off-by: Ivan Mikushin <imikushin@vmware.com>
tenczar
approved these changes
Apr 26, 2022
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.
LGTM with one question
Catch only label changes for Cluster objects. Signed-off-by: Ivan Mikushin <imikushin@vmware.com>
Signed-off-by: Ivan Mikushin <imikushin@vmware.com>
prkalle
approved these changes
Apr 27, 2022
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.
LGTM. Thank you!
Since UpdatesAvailable
condition would only show the latest upgradable version matching the cluster current kubernetes version's (major,minor) and (major,minor+1), It would be nice to mention this in the PR summary
anujc25
approved these changes
Apr 28, 2022
Since BOLT takes the base of the filepath, it would create the manifest with the name "status" which would confusing. Signed-off-by: Ivan Mikushin <imikushin@vmware.com>
Signed-off-by: Ivan Mikushin <imikushin@vmware.com>
# for free
to subscribe to this conversation on GitHub.
Already have an account?
#.
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.
What this PR does / why we need it
Implement the TKR Status Controller that:
UpdatesAvailable condition will only show the latest upgradable versions matching the cluster current Kubernetes version prefixes:
major.minor
andmajor.minor+1
.Also, make sure we return the TKR version (instead of the Kubernetes version) as available update if the update TKR has the same Kubernetes version.
TKR version can now be used directly in Cluster
spec.topology.version
field. The resolver webhook will use the TKR as though it was already resolved (if it satisfies the TKR and OSImage selectors, of course) and will setspec.topology.version
to the Kubernetes version of the TKR.Make sure resolved TKR is the same for both CP and MDs:
Which issue(s) this PR fixes
Fixes #1925
Describe testing done for PR
Unit testing with "generative" tests and hundreds of test runs.
Release note
PR Checklist
Additional information
Special notes for your reviewer