diff options
author | Erik Johnston <erik@matrix.org> | 2016-01-28 15:02:37 +0000 |
---|---|---|
committer | Erik Johnston <erik@matrix.org> | 2016-01-28 15:02:41 +0000 |
commit | e1941442d442fe62570551071edfd936304697e7 (patch) | |
tree | d0472b1d793fbb5942eb27fbd37e9d400c0aa742 /synapse/storage/events.py | |
parent | Merge branch 'develop' of github.com:matrix-org/synapse into erikj/sync (diff) | |
download | synapse-e1941442d442fe62570551071edfd936304697e7.tar.xz |
Invalidate caches properly. Remove unused arg
Diffstat (limited to 'synapse/storage/events.py')
-rw-r--r-- | synapse/storage/events.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/synapse/storage/events.py b/synapse/storage/events.py index 80187722ea..2d2270b297 100644 --- a/synapse/storage/events.py +++ b/synapse/storage/events.py @@ -128,9 +128,6 @@ class EventsStore(SQLBaseStore): is_new_state=is_new_state, current_state=current_state, ) - self._events_stream_cache.room_has_changed( - None, event.room_id, stream_ordering - ) except _RollbackButIsFineException: pass @@ -213,6 +210,12 @@ class EventsStore(SQLBaseStore): for event, _ in events_and_contexts: txn.call_after(self._invalidate_get_event_cache, event.event_id) + if not backfilled: + txn.call_after( + self._events_stream_cache.room_has_changed, + event.room_id, event.internal_metadata.stream_ordering, + ) + depth_updates = {} for event, _ in events_and_contexts: if event.internal_metadata.is_outlier(): |