-
Notifications
You must be signed in to change notification settings - Fork 63
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
Adds support for timeout per packet #45
Adds support for timeout per packet #45
Conversation
54de906
to
9401b7d
Compare
Signed-off-by: Ivo <ikunchev@gmail.com>
9401b7d
to
65e3cf1
Compare
This doesn't look like it does anything about per-packet timeouts. It only sets a timeout at the start of the loop, it doesn't seem to track the individual packet start and timeout times. |
What do you mean?
^^ this is checking each packet against the predefined packet value, therefore statistics are correct. The timeout is calculated so that the process is waiting for the last sent packet + packet timeout time. |
I don't think you understand what per-packet timeouts are. The Say I do this:
Note that the ping RTT in the above example is over 100ms. A per-packet timeout of 10ms should make all of those packets timeout. Your change does not actually do per-packet timeouts. |
As per your example above there is 100% packet loss. Each packet is checked against PacketTimeout by reading the Rtt. Do you refer to the per packet output of the |
Signed-off-by: Ivo <ikunchev@gmail.com>
fe4258e
to
2dc9076
Compare
@SuperQ I believe it works properly and it's a matter of display representation in the |
The problem you only account for lost packets on packet receive, and at the end. This needs to be implemented to happen in real-time so that a |
What is the use case for the |
The primary use case of this repos is it being used as a library in other monitoring projects. The reason we need a per-packet timeout is so that we can collect metrics about timeouts while the prober loop is running. It is essential to this. |
Sounds like a viable use-case. |
No, that won't work either. We need this to be as close to real-time as possible. |
This is an attempt at solving the timeout per packet issue using the rtt field.
The timeout timer is set to the lower value of request timeout / last packet sent timeout so that the pinger exits as soons as there is no more work to do.
Please have a look and share your thoughts.