-
Notifications
You must be signed in to change notification settings - Fork 176
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
Add RemoteKubernetesCluster finalizer #2272
Add RemoteKubernetesCluster finalizer #2272
Conversation
@zimnx: GitHub didn't allow me to request PR reviews from the following users: zimnx. Note that only scylladb members and repo collaborators can review this PR, and authors cannot review their own PRs. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: zimnx 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 |
c422af5
to
846eef0
Compare
Ready to review /cc rzetelskik |
test/e2e/set/remotekubernetescluster/remotekubernetescluster_finalizer.go
Outdated
Show resolved
Hide resolved
test/e2e/set/remotekubernetescluster/remotekubernetescluster_finalizer.go
Outdated
Show resolved
Hide resolved
test/e2e/set/remotekubernetescluster/remotekubernetescluster_finalizer.go
Outdated
Show resolved
Hide resolved
test/e2e/set/remotekubernetescluster/remotekubernetescluster_finalizer.go
Outdated
Show resolved
Hide resolved
test/e2e/set/remotekubernetescluster/remotekubernetescluster_finalizer.go
Outdated
Show resolved
Hide resolved
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 except for the typo
/assign rzetelskik
Resource: schema.GroupVersionResource{ | ||
Group: "scylla.scylladb.com", | ||
Version: "v1alpha1", | ||
Resource: "remotekuberneteclusters", |
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.
typo: missing trailing S
in kubernete
.
I'm worried that this isn't failing the tests. Is this gvr necessary indeed?
Furthermore - the fact that resource and kind literals are scattered across the codebase feels like a code smell. Not something to fix in this PR, but worth noting.
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.
It's there to remove conflicting cluster-wide resource in case it's there and restore after the test. These resources are not created as part of CI so it just passes silently and it's expected. Good catch!
Used scyllav1alpha1.GroupVersion constants since we already have them, but left resource name since we don't have it anywhere.
Controller reconciles finalizer on RemoteKubernetesCluster, preventing from premature deletion. It waits until all ScyllaDBClusters using particular RemoteKubernetesCluster are deleted.
846eef0
to
d74bf20
Compare
/lgtm |
Description of your changes:
Controller reconciles finalizer on RemoteKubernetesCluster, preventing from premature deletion. It waits until all ScyllaDBClusters using particular RemoteKubernetesCluster are deleted.
Which issue is resolved by this Pull Request:
Resolves #2277