From 0a6a966e2b86ebe423709c030634c04c1093ab0b Mon Sep 17 00:00:00 2001 From: Erik Johnston Date: Mon, 3 Apr 2017 15:22:56 +0100 Subject: [PATCH] Always advance stream tokens --- synapse/replication/tcp/resource.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/synapse/replication/tcp/resource.py b/synapse/replication/tcp/resource.py index b70fa7334..0d7ea5731 100644 --- a/synapse/replication/tcp/resource.py +++ b/synapse/replication/tcp/resource.py @@ -121,7 +121,10 @@ class ReplicationStreamer(object): is currently being executed, so that nothing gets missed """ if not self.connections: - # Don't bother if nothing is listening + # Don't bother if nothing is listening. We still need to advance + # the stream tokens otherwise they'll fall beihind forever + for stream in self.streams: + stream.advance_current_token() return # If we're in the process of checking for new updates, mark that fact