summary refs log tree commit diff
path: root/synapse/app/client_reader.py
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2019-07-22 15:22:14 +0100
committerErik Johnston <erik@matrix.org>2019-07-22 15:22:14 +0100
commit80cfad233efc6b03c75ab5496db7079466eeb894 (patch)
treefbf153921c3d7dec38961dcb332b890b5c169342 /synapse/app/client_reader.py
parentNewsfile (diff)
downloadsynapse-80cfad233efc6b03c75ab5496db7079466eeb894.tar.xz
Call startup commands as system triggers.
This helps ensures that we only consider ourselves "up" once all the
startup functions have completed.
Diffstat (limited to 'synapse/app/client_reader.py')
-rw-r--r--synapse/app/client_reader.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/synapse/app/client_reader.py b/synapse/app/client_reader.py
index 29bddc4823..721bb5b119 100644
--- a/synapse/app/client_reader.py
+++ b/synapse/app/client_reader.py
@@ -194,7 +194,9 @@ def start(config_options):
     )
 
     ss.setup()
-    reactor.callWhenRunning(_base.start, ss, config.worker_listeners)
+    reactor.addSystemEventTrigger(
+        "before", "startup", _base.start, ss, config.worker_listeners
+    )
 
     _base.start_worker_reactor("synapse-client-reader", config)