diff --git a/changelog.d/19633.misc b/changelog.d/19633.misc new file mode 100644 index 0000000000..37efd5309f --- /dev/null +++ b/changelog.d/19633.misc @@ -0,0 +1 @@ +Document context for why increase timeout for policy server requests. diff --git a/synapse/handlers/room_policy.py b/synapse/handlers/room_policy.py index fee3c6cfaf..01943e1991 100644 --- a/synapse/handlers/room_policy.py +++ b/synapse/handlers/room_policy.py @@ -223,11 +223,16 @@ class RoomPolicyHandler: return # Ask the policy server to sign this event. - # We set a smallish timeout here as we don't want to block event sending too long. try: signature = await self._federation_client.ask_policy_server_to_sign_event( policy_server.server_name, event, + # We set a smallish timeout here as we don't want to block event sending + # too long. + # + # We were previously seeing regular timeouts with media + # scanning/checking when the timeout was set to 3s. 30s was chosen based + # on vibes and light real world testing. timeout=30000, ) # TODO: We can *probably* remove this when we remove unstable MSC4284 support.