Skip to content
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

Sometimes response_count > request_total #62

Open
liboz opened this issue Jan 14, 2022 · 1 comment
Open

Sometimes response_count > request_total #62

liboz opened this issue Jan 14, 2022 · 1 comment

Comments

@liboz
Copy link

liboz commented Jan 14, 2022

Thanks for writing this project. It's pretty much exactly what I wanted. However, I noticed an odd issue while sanity checking the data. Sometimes, there are times when response_count > request_total. This seems intuitively incorrect.

I'm running with an interval of 250ms between pings and this is my prometheus query: increase(smokeping_response_duration_seconds_count{}[10s]) / increase(smokeping_requests_total{}[10s])
image

Looking at the upstream library, I'd suspect that it's because increment to the PacketsSent value https://github.com/go-ping/ping/blob/779d1e9195345226ee7c43c82dd062fd0acdd419/ping.go#L758
happens after the connection is actually written to
https://github.com/go-ping/ping/blob/779d1e9195345226ee7c43c82dd062fd0acdd419/ping.go#L737

I'm not so familiar with the code there so I was wondering if I'm totally off base and there's something else at play here.

@SuperQ
Copy link
Owner

SuperQ commented Jan 14, 2022

Hmm, that could be. There's an open PR that may be related (go-ping/ping#196).

Previously, the ping library didn't have an OnSend callback. This might be a little more reliable from a jitter perspective.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants