-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Delay init of http phase values #865
Conversation
Mmmmh that's an interesting PR, it means that averages etc will only work when a phase is executed, I am not sure we should do this. |
@roidelapluie It's a difficult choice. The problem is we emit 0 for things we have explicitly not measured, which is what the original issue is about. |
But if probe_success == 0 you should not run analytics over them either. |
how would you exclude those series that were obtained with an error |
I've been thinking this further. When HAProxy Exporter can not scrape HAProxy, it does not return zero-ed metrics. We should do the same here. |
Don't init http probe phase labels until we're ready to send the request. Avoids exposing 0 value samples for things we haven't started to measure. Fix http resolve timing to report lookup time even if it's an error (ie not found). Fixes: #579 Signed-off-by: SuperQ <superq@gmail.com>
70066b8
to
06c0ccc
Compare
I also added a fix for the "resolve" phase. It now accounts for the resolve phase time even if the resolve result is a failure. |
Thanks! |
Don't init http probe phase labels until we're ready to send the
request.
Avoids exposing 0 value samples for things we haven't started to
measure.
Fix http resolve timing to report lookup time even if it's an error
(ie not found).
Fixes: #579
Signed-off-by: SuperQ superq@gmail.com