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

Commit

Permalink
Review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
clokep authored Aug 3, 2023
1 parent 033e59f commit 2e633c3
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions synapse/config/federation.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,11 +69,8 @@ def read_config(self, config: JsonDict, **kwargs: Any) -> None:
# when trying to reach an unavailable destination.
# Unlike previous configuration those values applies across
# multiple requests and the state of the backoff is stored on DB.
self.destination_min_retry_interval_ms = min(
Config.parse_duration(
federation_config.get("destination_min_retry_interval", "10m")
),
2**62,
self.destination_min_retry_interval_ms = Config.parse_duration(
federation_config.get("destination_min_retry_interval", "10m")
)
self.destination_retry_multiplier = federation_config.get(
"destination_retry_multiplier", 2
Expand All @@ -82,6 +79,7 @@ def read_config(self, config: JsonDict, **kwargs: Any) -> None:
Config.parse_duration(
federation_config.get("destination_max_retry_interval", "7d")
),
# Set a hard-limit to not overflow the database column.
2**62,
)

Expand Down

0 comments on commit 2e633c3

Please sign in to comment.