0
0
Fork 1
mirror of https://mau.dev/maunium/synapse.git synced 2024-12-15 02:03:51 +01:00

Don't do long retries when calling the key notary server. (#5334)

It takes at least 20 minutes to work through the long_retries schedule (11
attempts, each with a 60 second timeout, and 60 seconds between each request),
so if the notary server isn't returning within the timeout, we'll just end up
blocking whatever request is happening for 20 minutes.

Ain't nobody got time for that.
This commit is contained in:
Richard van der Hoff 2019-06-04 11:53:07 +01:00 committed by GitHub
parent cb683d3e3c
commit 4d08b8f30c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 1 additions and 1 deletions

1
changelog.d/5334.bugfix Normal file
View file

@ -0,0 +1 @@
Fix bug which would make certain operations (such as room joins) block for 20 minutes while attemoting to fetch verification keys.

View file

@ -644,7 +644,6 @@ class PerspectivesKeyFetcher(BaseV2KeyFetcher):
for server_name, server_keys in keys_to_fetch.items() for server_name, server_keys in keys_to_fetch.items()
} }
}, },
long_retries=True,
) )
except (NotRetryingDestination, RequestSendFailed) as e: except (NotRetryingDestination, RequestSendFailed) as e:
raise_from(KeyLookupError("Failed to connect to remote server"), e) raise_from(KeyLookupError("Failed to connect to remote server"), e)