-
Notifications
You must be signed in to change notification settings - Fork 9
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 a endpoint based sync point after scaling up the pods in import step #14
Add a endpoint based sync point after scaling up the pods in import step #14
Conversation
Signed-off-by: Sergen Yalçın <yalcinsergen97@gmail.com>
9d3d078
to
3e1eca3
Compare
fi | ||
done | ||
|
||
if ${KUBECTL} get managed ; then |
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.
The API conversion functions (invoked by the conversion webhooks) may not kick in here, if the CRD API storage version is the highest priority version, e.g., when the available versions are v1beta1
and v1beta2
and the storage version is v1beta2
.
How about parameterizing this function with the arguments to be passed to kubectl
and retry the actual command for a finite count till it succeeds?
Looks like we should also be able to utilize a DeploymentRuntimeConfig
to introduce a readiness probe for the webhook service. This together with the check on the endpoints can be an alternative.
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 added another script to retry the patch step.
Signed-off-by: Sergen Yalçın <yalcinsergen97@gmail.com>
b67322a
to
840f4e7
Compare
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.
Thanks @sergenyalcin, lgtm.
- script: | | ||
#!/bin/bash | ||
|
||
function check_endpoints { |
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.
Isn't it possible to define a generic kubectl_retry
function that will retry the passed kubectl
command together with its arguments and call it for kubectl get endpoints
& kubectl patch
?
Signed-off-by: Sergen Yalçın <yalcinsergen97@gmail.com>
3b4b1b0
to
701c15b
Compare
Description of your changes
Follow-up of #13. We observed some issues on pod-based sync point for import step in provider-gcp tests. This PR adds an endpoint-based sync point after scaling up the pods in import step.
kubectl patch
steps.I have:
make reviewable test
to ensure this PR is ready for review.How has this code been tested
Tested locally.