summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--changelog.d/9664.misc1
-rw-r--r--synapse/federation/sender/per_destination_queue.py2
2 files changed, 3 insertions, 0 deletions
diff --git a/changelog.d/9664.misc b/changelog.d/9664.misc
new file mode 100644
index 0000000000..3d410ed4cd
--- /dev/null
+++ b/changelog.d/9664.misc
@@ -0,0 +1 @@
+Improve performance of federation catch up by sending events the latest events in the room to the remote, rather than just the last event sent by the local server.
diff --git a/synapse/federation/sender/per_destination_queue.py b/synapse/federation/sender/per_destination_queue.py
index af85fe0a1e..89df9a619b 100644
--- a/synapse/federation/sender/per_destination_queue.py
+++ b/synapse/federation/sender/per_destination_queue.py
@@ -480,6 +480,8 @@ class PerDestinationQueue:
                     # the other sending servers are up).
                     if new_pdus:
                         room_catchup_pdus = new_pdus
+                    else:
+                        room_catchup_pdus = [pdu]
 
                 logger.info(
                     "Catching up rooms to %s: %r", self._destination, pdu.room_id