-
Notifications
You must be signed in to change notification settings - Fork 287
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 flag to set machine health check timeout (#3918) #4123
Conversation
Hi @msanjaq. Thanks for your PR. I'm waiting for a aws member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. 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. |
/ok-to-test |
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 realized that we have a set of timeout flags here, can we add it there instead?
flagSet.StringVar(&t.externalEtcdWaitTimeout, externalEtcdWaitTimeoutFlag, clustermanager.DefaultEtcdWait.String(), "Override the default external etcd wait timeout (60m)") |
Codecov Report
@@ Coverage Diff @@
## main #4123 +/- ##
==========================================
+ Coverage 67.55% 67.62% +0.06%
==========================================
Files 396 398 +2
Lines 32005 32092 +87
==========================================
+ Hits 21622 21702 +80
- Misses 8960 8964 +4
- Partials 1423 1426 +3
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
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.
/approve
Before this change, an unhealthy machine health check would timeout after five minutes. This leads to an endless loop for a RolingUpgrade on a slow system. Disabling the health checks circumvents this issue, but is not ideal. This change adds a --unhealthy-machine-timeout flag which customers can use to make the upgrade process more reliable without sacrificing health checks.
kind: MachineHealthCheck | ||
metadata: | ||
creationTimestamp: null | ||
name: fluxTestCluster-worker-1-worker-unhealthy | ||
namespace: eksa-system | ||
spec: | ||
clusterName: fluxTestCluster | ||
maxUnhealthy: 40% | ||
maxUnhealthy: 40%% |
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.
Is this a mistake?
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.
No, this is intentional. The '%%' is converted to '%' by sprintf.
https://stackoverflow.com/questions/35681595/escape-variables-with-printf
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.
Oh so it wasn't validating before?
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.
/approve
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: vivek-koppuru 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 |
Before this change, an unhealthy machine health check would timeout after five minutes. This leads to an endless loop for a RolingUpgrade on a slow system. Disabling the health checks circumvents this issue, but is not ideal. This change adds a --unhealthy-machine-timeout flag which customers can use to make the upgrade process more reliable without sacrificing health checks.
Before this change, an unhealthy machine health check would timeout after five minutes. This leads to an endless loop for a RolingUpgrade on a slow system. Disabling the health checks circumvents this issue, but is not ideal. This change adds a flag
--unhealthy-machine-timeout
which customers can use to make the upgrade process more reliable without sacrificing health checks.Issue #, if available: Resolves #3918
Description of changes: Allow users to override the default unhealthy machine condition timeout using an
--unhealthy-machine-timeout
flagTesting (if applicable):
Created unit tests for the scenarios:
I performed a manual test by running the command
eksctl anywhere create cluster --unhealthy-machine-timeout 20m -f mgmt_cluster.yaml
and confirmed the timeout was set correctly with
kubectl get -o yaml machinehealthcheck -A --kubeconfig sanjaqmo-healthcheck-test-mgmt/sanjaqmo-healthcheck-test-mgmt-eks-a-cluster.kubeconfig
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.