diff --git a/synapse/push/emailpusher.py b/synapse/push/emailpusher.py index f72284d09edf..be7631e8d0a2 100644 --- a/synapse/push/emailpusher.py +++ b/synapse/push/emailpusher.py @@ -33,7 +33,6 @@ # THROTTLE is the minimum time between mail notifications sent for a given room. # Each room maintains its own throttle counter, but each new mail notification # sends the pending notifications for all rooms. -THROTTLE_START_MS = 10 * 60 * 1000 THROTTLE_MAX_MS = 24 * 60 * 60 * 1000 # 24h # THROTTLE_MULTIPLIER = 6 # 10 mins, 1 hour, 6 hours, 24 hours THROTTLE_MULTIPLIER = 144 # 10 mins, 24 hours - i.e. jump straight to 1 day @@ -298,10 +297,10 @@ async def sent_notif_update_throttle( current_throttle_ms = self.get_room_throttle_ms(room_id) if gap > THROTTLE_RESET_AFTER_MS: - new_throttle_ms = THROTTLE_START_MS + new_throttle_ms = self._delay_before_mail_ms else: if current_throttle_ms == 0: - new_throttle_ms = THROTTLE_START_MS + new_throttle_ms = self._delay_before_mail_ms else: new_throttle_ms = min( current_throttle_ms * THROTTLE_MULTIPLIER, THROTTLE_MAX_MS