summary refs log tree commit diff
path: root/synapse/storage/stream.py
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2015-08-07 14:42:34 +0100
committerErik Johnston <erik@matrix.org>2015-08-07 14:42:34 +0100
commitb2c7bd4b098bea86189b2c8323265e23673d257d (patch)
treebd407139c6f624a5eb95515488acbdf3467726f2 /synapse/storage/stream.py
parentRemove unncessary cache (diff)
downloadsynapse-b2c7bd4b098bea86189b2c8323265e23673d257d.tar.xz
Cache get_recent_events_for_room
Diffstat (limited to 'synapse/storage/stream.py')
-rw-r--r--synapse/storage/stream.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/synapse/storage/stream.py b/synapse/storage/stream.py
index 9db259d5fc..b59fe81004 100644
--- a/synapse/storage/stream.py
+++ b/synapse/storage/stream.py
@@ -35,7 +35,7 @@ what sort order was used:
 
 from twisted.internet import defer
 
-from ._base import SQLBaseStore
+from ._base import SQLBaseStore, cachedInlineCallbacks
 from synapse.api.constants import EventTypes
 from synapse.types import RoomStreamToken
 from synapse.util.logutils import log_function
@@ -299,7 +299,7 @@ class StreamStore(SQLBaseStore):
 
         defer.returnValue((events, token))
 
-    @defer.inlineCallbacks
+    @cachedInlineCallbacks(num_args=4)
     def get_recent_events_for_room(self, room_id, limit, end_token, from_token=None):
         # TODO (erikj): Handle compressed feedback