summary refs log tree commit diff
path: root/synapse/federation/sender/per_destination_queue.py
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2022-03-04 11:48:15 +0000
committerGitHub <noreply@github.com>2022-03-04 11:48:15 +0000
commit423cca9efe06d78aaca5f62fb74ee7e5bceebe49 (patch)
tree8b8e5fe7e6fe30767f250c5f05e6c9c5200d4ae4 /synapse/federation/sender/per_destination_queue.py
parentUpdate client-visibility filtering for outlier events (#12155) (diff)
downloadsynapse-423cca9efe06d78aaca5f62fb74ee7e5bceebe49.tar.xz
Spread out sending device lists to remote hosts (#12132)
Diffstat (limited to 'synapse/federation/sender/per_destination_queue.py')
-rw-r--r--synapse/federation/sender/per_destination_queue.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/synapse/federation/sender/per_destination_queue.py b/synapse/federation/sender/per_destination_queue.py
index c8768f22bc..d80f0ac5e8 100644
--- a/synapse/federation/sender/per_destination_queue.py
+++ b/synapse/federation/sender/per_destination_queue.py
@@ -219,6 +219,16 @@ class PerDestinationQueue:
         self._pending_edus.append(edu)
         self.attempt_new_transaction()
 
+    def mark_new_data(self) -> None:
+        """Marks that the destination has new data to send, without starting a
+        new transaction.
+
+        If a transaction loop is already in progress then a new transcation will
+        be attempted when the current one finishes.
+        """
+
+        self._new_data_to_send = True
+
     def attempt_new_transaction(self) -> None:
         """Try to start a new transaction to this destination