summary refs log tree commit diff
path: root/synapse/handlers/message.py
diff options
context:
space:
mode:
authorSean Quah <8349537+squahtx@users.noreply.github.com>2022-07-26 12:39:23 +0100
committerGitHub <noreply@github.com>2022-07-26 12:39:23 +0100
commit335ebb21ccc0ae906169f21dcfc456c869bdd301 (patch)
treed79c423c2592b719fe02ffc6bb6f40f5f4416aed /synapse/handlers/message.py
parentRemove unused argument for get_relations_for_event. (#13383) (diff)
downloadsynapse-335ebb21ccc0ae906169f21dcfc456c869bdd301.tar.xz
Faster room joins: avoid blocking when pulling events with missing prevs (#13355)
Avoid blocking on full state in `_resolve_state_at_missing_prevs` and
return a new flag indicating whether the resolved state is partial.
Thread that flag around so that it makes it into the event context.

Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com>
Diffstat (limited to 'synapse/handlers/message.py')
-rw-r--r--synapse/handlers/message.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/synapse/handlers/message.py b/synapse/handlers/message.py
index bd7baef051..e0bcc40b93 100644
--- a/synapse/handlers/message.py
+++ b/synapse/handlers/message.py
@@ -1135,6 +1135,10 @@ class EventCreationHandler:
             context = await self.state.compute_event_context(
                 event,
                 state_ids_before_event=state_map_for_event,
+                # TODO(faster_joins): check how MSC2716 works and whether we can have
+                #   partial state here
+                #   https://github.com/matrix-org/synapse/issues/13003
+                partial_state=False,
             )
         else:
             context = await self.state.compute_event_context(event)