-
Notifications
You must be signed in to change notification settings - Fork 51
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
sink: wait for infra-agent to be ready before starting #346
Conversation
yes, I noticed that as well, thanks for taking care of it! |
b1a0636
to
9876189
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.
LGTM
_ = resp.Body.Close() | ||
|
||
if resp.StatusCode != http.StatusOK { | ||
return fmt.Errorf("%w: %d", errProbeNotOk, resp.StatusCode) |
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.
perhaps you can get rid of the errProbeNotOk
var since is just for loggin
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 planned to do so but I'm not sure if the linter would complain in this case. Since I already had the var created from a previous iteration where this error was somewhere returned) I left it there, but we can remove it if you want!
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.
Looks good! thanks for adding the exported Func comments
fixup! cosmetic refactoring fixup! rename to wrapper.go
Since we are now waiting using the prober, errors POSTing data to the sidecar are actually concerning
Co-authored-by: Guillermo Sanchez Gavier <gsanchez@newrelic.com>
As the title says, after upgrading the
nri-bundle
on my local environment, thenrk8s-ksm
pod restarted 3 times while waiting for the agent to become ready.nrk8s-kubelet
restarted twice. This simple trick should make a more graceful wait without alerting the user if the agent does not come up immediately.