1
0

Fix bug in calculating the federation retry backoff period (#6025)

This commit is contained in:
Andrew Morgan
2020-02-25 14:27:19 +00:00
2 changed files with 4 additions and 2 deletions
+1
View File
@@ -0,0 +1 @@
Fix bug in calculating the federation retry backoff period.
+3 -2
View File
@@ -193,8 +193,9 @@ class RetryDestinationLimiter(object):
else:
# We couldn't connect.
if self.retry_interval:
self.retry_interval *= RETRY_MULTIPLIER
self.retry_interval *= int(random.uniform(0.8, 1.4))
self.retry_interval = int(
self.retry_interval * RETRY_MULTIPLIER * random.uniform(0.8, 1.4)
)
if self.retry_interval >= MAX_RETRY_INTERVAL:
self.retry_interval = MAX_RETRY_INTERVAL