-
Notifications
You must be signed in to change notification settings - Fork 159
Adding leader election to controllers in staging rc #518
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
@verult: GitHub didn't allow me to request PR reviews from the following users: ffilippopoulos. Note that only kubernetes-sigs 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/test-infra repository. |
/test pull-gcp-compute-persistent-disk-csi-driver-kubernetes-integration Only one test failed, so assuming it's a flake |
- target: | ||
group: apps | ||
version: v1 | ||
kind: StatefulSet |
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.
Do we want to switch to a Deployment as well? I think it's not easily done without modifying the base too
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.
I'm leaning towards optimizing for the common case of 1 replica. I think this is the common case, but if we have indicators otherwise we could change it
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.
Maybe let's set the pod management policy to "parallel" then? That way the statefulset won't get stuck if one of the replicas fail.
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.
Actually looking at the design doc again, StatefulSet is good for a dedicated node, which is probably usually not the case for this deployment. I can switch it to Deployment.
At some point I managed to change the kind
with a Kustomize JSON patch. Will see if I can still do it :)
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.
I think this low risk enough to just do it in the base. There's probably other spec differences between StatefulSet and Deployment too.
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.
Got the patching figured out. I pushed a new version
I believe the default of maxUnavailable = 25% (rounded down, so 0) and maxSurge = 25% (rounded up, so 1) is OK - a new replica will be created first, in standby, before the old replica is deleted.
version: v1 | ||
kind: StatefulSet | ||
name: csi-gce-pd-controller | ||
path: statefulset-to-deployment.yaml |
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.
File is missing
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.
agh sorry, added
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: msau42, verult 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 type of PR is this?
/kind feature
What this PR does / why we need it:
Which issue(s) this PR fixes:
First step in releasing change for #516
Special notes for your reviewer:
Does this PR introduce a user-facing change?:
/assign @msau42
/cc ffilippopoulos