diff options
author | Erik Johnston <erik@matrix.org> | 2020-04-22 13:07:41 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-22 13:07:41 +0100 |
commit | 51f7eaf908a84fcaf231899e2bf1beae14ae72c0 (patch) | |
tree | e7e14016f42d021542d1703415cf6e06804310eb /synapse/app | |
parent | Reduce logging verbosity of URL cache cleanup. (#7295) (diff) | |
download | synapse-51f7eaf908a84fcaf231899e2bf1beae14ae72c0.tar.xz |
Add ability to run replication protocol over redis. (#7040)
This is configured via the `redis` config options.
Diffstat (limited to 'synapse/app')
-rw-r--r-- | synapse/app/homeserver.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/synapse/app/homeserver.py b/synapse/app/homeserver.py index 49df63acd0..cbd1ea475a 100644 --- a/synapse/app/homeserver.py +++ b/synapse/app/homeserver.py @@ -273,6 +273,12 @@ class SynapseHomeServer(HomeServer): def start_listening(self, listeners): config = self.get_config() + if config.redis_enabled: + # If redis is enabled we connect via the replication command handler + # in the same way as the workers (since we're effectively a client + # rather than a server). + self.get_tcp_replication().start_replication(self) + for listener in listeners: if listener["type"] == "http": self._listening_services.extend(self._listener_http(config, listener)) |