-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Machine deletion: try up to n times to delete the Node, then move on #1446
Comments
/assign |
@ncdc I'm thinking of wrapping this function inside |
That seems AWS specific function, for this we should probably just retry a specific number of times. We should be able to use https://github.com/kubernetes/apimachinery/blob/master/pkg/util/wait/wait.go#L333 to achieve this, wdyt? |
yes, i'm actually talking about this! |
any suggestion for interval and timeout duration? |
Sounds good, I saw the linked aws code and was confused :D I'd retry maybe every 2 seconds and for max 10? @ncdc |
Do you think it makes sense to try for up to either 30 or 60 seconds? Or is it more likely that if it fails once, it will probably fail every time, in which case trying for that long is an unnecessary delay? |
Or should we just try once and not even bother with any more attempts? |
Once might be a temporary failure, I'd limit it the retries to 10-15 seconds, if it fails for that long there is a good chance that we won't be able to reach it |
Ok, I'm good with interval=2s, timeout=10s |
Should we do the same for bastion? |
The bastion is CAPA specific and is unrelated to this issue (the bastion doesn't have a corresponding Kubernetes Node). |
oops, I mistook it as a capa issue, thats why i was linking the capa function :( |
What steps did you take and what happened:
kubectl delete machine/foo
What did you expect to happen:
This error shouldn't block Machine deletion
Anything else you would like to add:
I think it would be reasonable to attempt to delete the Node multiple times over the span of 30-60 seconds. If the deletion fails, we can record an Event, then allow the Machine deletion to continue.
Environment:
/kind bug
xref kubernetes-sigs/cluster-api-provider-aws#1084 (comment) and my next comment as well
The text was updated successfully, but these errors were encountered: