You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To recap: system clock is constantly floating and it doesn't move only forwards. If your calculation of elapsed time is based on it, you're very likely to run into calculation errors or even outages.
At a glance I only found one place where this has to be changed:
The text was updated successfully, but these errors were encountered:
ghost
changed the title
Request duration measurements use the wrong mechanism
Request duration measurements aren't using a monotonic clock
Feb 22, 2022
Right now Kiev is using the difference between the return values of
Time.now
to calculate request duration. Instead, it should be using a process' monotonic clock as outlined in the article here: https://blog.dnsimple.com/2018/03/elapsed-time-with-ruby-the-right-way/:At a glance I only found one place where this has to be changed:
kiev/lib/kiev/request_logger.rb
Lines 10 to 20 in 8cba28a
…but there may be more.
The text was updated successfully, but these errors were encountered: