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
The current algorithm always sleeps for the rate period, not taking into account that sending requests takes a little time.
For example, for a rate of 10 requests/s, the timing are something like:
Action
Time
0
start
sleep 100
105*
send
125
sleep 100
235*
send
250
sleep 100
355*
send
...
(*) sleeps may not be accurate.
Requests are sent at 105, 235 and 355, which is not very time-accurate, as they should happen at 100, 200 and 300.
Furthermore, over time the cost of sending and the oversleeps accumulate.
Instead, this is more time-accurate:
Action
Time
0
start
sleep 100
105*
send
125
sleep 100 - 25
210*
send
225
sleep 100 - 25
305*
send
...
Requests are sent at 105, 210 and 305 which is more accurate with the nominal times of 100, 200 and 300.
The text was updated successfully, but these errors were encountered:
The current algorithm always sleeps for the rate period, not taking into account that sending requests takes a little time.
For example, for a rate of 10 requests/s, the timing are something like:
(*) sleeps may not be accurate.
Requests are sent at
105
,235
and355
, which is not very time-accurate, as they should happen at100
,200
and300
.Furthermore, over time the cost of sending and the oversleeps accumulate.
Instead, this is more time-accurate:
Requests are sent at
105
,210
and305
which is more accurate with the nominal times of100
,200
and300
.The text was updated successfully, but these errors were encountered: