Skip to content
This repository was archived by the owner on Apr 26, 2024. It is now read-only.

Commit bceec65

Browse files
committed
Slightly more aggressive retry timers at HTTP level
1 parent 9eff52d commit bceec65

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

synapse/http/matrixfederationclient.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@
5656
)
5757

5858

59-
MAX_RETRIES = 4
59+
MAX_RETRIES = 10
6060

6161

6262
class MatrixFederationEndpointFactory(object):
@@ -184,7 +184,8 @@ def send_request():
184184
)
185185

186186
if retries_left and not timeout:
187-
delay = 5 ** (MAX_RETRIES + 1 - retries_left)
187+
delay = 4 ** (MAX_RETRIES + 1 - retries_left)
188+
delay = max(delay, 60)
188189
delay *= random.uniform(0.8, 1.4)
189190
yield sleep(delay)
190191
retries_left -= 1

0 commit comments

Comments
 (0)