summary refs log tree commit diff
path: root/synapse/storage
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2016-01-21 15:12:56 +0000
committerErik Johnston <erik@matrix.org>2016-01-21 15:12:56 +0000
commit82b46f556d5e35948f6200abc55b532923457be5 (patch)
treeb71c0f273608c036ad721868d4aa945b37f2f416 /synapse/storage
parentFix AttributeError (diff)
parentCache get_unread_event_push_actions_by_room_for_user (diff)
downloadsynapse-82b46f556d5e35948f6200abc55b532923457be5.tar.xz
Merge pull request #516 from matrix-org/erikj/push_perf
Reduce number of calls to get_unread_event_push_actions_by_room
Diffstat (limited to 'synapse/storage')
-rw-r--r--synapse/storage/event_push_actions.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/synapse/storage/event_push_actions.py b/synapse/storage/event_push_actions.py

index 6b7cebc9ce..aa61cf5569 100644 --- a/synapse/storage/event_push_actions.py +++ b/synapse/storage/event_push_actions.py
@@ -15,6 +15,7 @@ from ._base import SQLBaseStore from twisted.internet import defer +from synapse.util.caches.descriptors import cachedInlineCallbacks import logging import ujson as json @@ -46,7 +47,7 @@ class EventPushActionsStore(SQLBaseStore): values ) - @defer.inlineCallbacks + @cachedInlineCallbacks(num_args=3) def get_unread_event_push_actions_by_room_for_user( self, room_id, user_id, last_read_event_id ):