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

Commit

Permalink
Only expire old sessions on the master.
Browse files Browse the repository at this point in the history
  • Loading branch information
clokep committed Apr 21, 2020
1 parent 1ac4976 commit 67d5d63
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions synapse/handlers/auth.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,12 +111,13 @@ def __init__(self, hs):
self._clock = self.hs.get_clock()

# Expire old UI auth sessions after a period of time.
self._clock.looping_call(
run_as_background_process,
5 * 60 * 1000,
"expire_old_sessions",
self.expire_old_sessions,
)
if hs.config.worker_name is None:
self._clock.looping_call(
run_as_background_process,
5 * 60 * 1000,
"expire_old_sessions",
self.expire_old_sessions,
)

# Load the SSO HTML templates.

Expand Down

0 comments on commit 67d5d63

Please sign in to comment.