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

Commit

Permalink
Reduce spurious replication catchup
Browse files Browse the repository at this point in the history
  • Loading branch information
erikjohnston committed Oct 26, 2023
1 parent c14a7de commit 0551f30
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions synapse/replication/tcp/handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -614,7 +614,7 @@ async def _process_position(
# If the position token matches our current token then we're up to
# date and there's nothing to do. Otherwise, fetch all updates
# between then and now.
missing_updates = cmd.prev_token != current_token
missing_updates = cmd.prev_token > current_token
while missing_updates:
# Note: There may very well not be any new updates, but we check to
# make sure. This can particularly happen for the event stream where
Expand Down Expand Up @@ -644,7 +644,7 @@ async def _process_position(
[stream.parse_row(row) for row in rows],
)

logger.info("Caught up with stream '%s' to %i", stream_name, cmd.new_token)
logger.info("Caught up with stream '%s' to %i", stream_name, current_token)

# We've now caught up to position sent to us, notify handler.
await self._replication_data_handler.on_position(
Expand Down

0 comments on commit 0551f30

Please sign in to comment.