summary refs log tree commit diff
diff options
context:
space:
mode:
authorErik Johnston <erikj@jki.re>2016-07-20 13:39:16 +0100
committerGitHub <noreply@github.com>2016-07-20 13:39:16 +0100
commitaba0b2a39bffddb8f013eb139fc1043b671286ae (patch)
tree4ef39a52a1bb5eab4b13b1f28313c841456a0e74
parentMerge pull request #933 from matrix-org/rav/type_annotations (diff)
parentDon't notify pusher pool for backfilled events (diff)
downloadsynapse-aba0b2a39bffddb8f013eb139fc1043b671286ae.tar.xz
Merge pull request #935 from matrix-org/erikj/backfill_notifs
Don't notify pusher pool for backfilled events
-rw-r--r--synapse/handlers/federation.py11
1 files changed, 6 insertions, 5 deletions
diff --git a/synapse/handlers/federation.py b/synapse/handlers/federation.py
index 7622962d46..3f138daf17 100644
--- a/synapse/handlers/federation.py
+++ b/synapse/handlers/federation.py
@@ -1118,11 +1118,12 @@ class FederationHandler(BaseHandler):
             backfilled=backfilled,
         )
 
-        # this intentionally does not yield: we don't care about the result
-        # and don't need to wait for it.
-        preserve_fn(self.hs.get_pusherpool().on_new_notifications)(
-            event_stream_id, max_stream_id
-        )
+        if not backfilled:
+            # this intentionally does not yield: we don't care about the result
+            # and don't need to wait for it.
+            preserve_fn(self.hs.get_pusherpool().on_new_notifications)(
+                event_stream_id, max_stream_id
+            )
 
         defer.returnValue((context, event_stream_id, max_stream_id))