added a small margin for the latency estimation
This commit is contained in:
parent
cad8221887
commit
1fbcf7b7c2
1 changed files with 1 additions and 1 deletions
|
@ -70,7 +70,7 @@ class MasterRole(base.BaseActiveRole):
|
|||
)
|
||||
)
|
||||
# if there is not enough data, default to 5 seconds of latency
|
||||
latency = timedelta(seconds=1) if len(latencies) <= 1 else numpy.max(latencies)
|
||||
latency = timedelta(seconds=1) if len(latencies) <= 1 else (numpy.max(latencies) + timedelta(seconds=0.5))
|
||||
|
||||
# if the calculated latency is higher than the current one, update it
|
||||
if latency > self.latency:
|
||||
|
|
Loading…
Reference in a new issue