-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
use a monotonous timer #3570
use a monotonous timer #3570
Conversation
Codecov ReportBase: 85.50% // Head: 85.73% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## master #3570 +/- ##
==========================================
+ Coverage 85.50% 85.73% +0.23%
==========================================
Files 139 140 +1
Lines 10244 10634 +390
==========================================
+ Hits 8759 9117 +358
- Misses 1103 1123 +20
- Partials 382 394 +12
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
771a98a
to
d9d0202
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.
This assumes that we never rely on this behavior to not get stuck. I guess the test suite is good enough for that…? :/
There's no point in having the timer fire multiple times for the same timestamp. By using a monotonuos timer we avoid busy-looping in cases where the timer fires, but we can't actually send a packet.
d9d0202
to
11cbf1e
Compare
The assumption is that when any timer fires at That said, I'd consider this PR an improvement, because even if we miss something here, worst case is that that one connection is eventually killed by the idle timeout. Previously, we'd effectively kill the node by busy-looping. |
There's no point in having the timer fire multiple times for the same timestamp. By using a monotonuos timer we avoid busy-looping in cases where the timer fires, but we can't actually send a packet.
Fixes #3567. Fixes #3179.
There's no point in having the timer fire multiple times for the same
timestamp. By using a monotonous timer we avoid busy-looping in cases where the
timer fires, but we can't actually send a packet.