summary refs log tree commit diff
path: root/synapse/storage/state.py
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2017-05-02 10:40:31 +0100
committerErik Johnston <erik@matrix.org>2017-05-02 10:40:31 +0100
commita2c89a225c567df53cc6d29af397547f4e9a4a2f (patch)
tree31c4b547d0c993b0424148bebfe374139be7a61b /synapse/storage/state.py
parentMerge pull request #2080 from matrix-org/erikj/filter_speed (diff)
downloadsynapse-a2c89a225c567df53cc6d29af397547f4e9a4a2f.tar.xz
Prefill state caches
Diffstat (limited to 'synapse/storage/state.py')
-rw-r--r--synapse/storage/state.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/synapse/storage/state.py b/synapse/storage/state.py
index a16afa8df5..1e1ce87e0e 100644
--- a/synapse/storage/state.py
+++ b/synapse/storage/state.py
@@ -227,6 +227,14 @@ class StateStore(SQLBaseStore):
                     ],
                 )
 
+            txn.call_after(
+                self._state_group_cache.update,
+                self._state_group_cache.sequence,
+                key=context.state_group,
+                value=context.current_state_ids,
+                full=True,
+            )
+
         self._simple_insert_many_txn(
             txn,
             table="event_to_state_groups",