summary refs log tree commit diff
path: root/synapse/handlers/room.py
diff options
context:
space:
mode:
authorErik Johnston <erikj@jki.re>2016-10-24 13:58:28 +0100
committerGitHub <noreply@github.com>2016-10-24 13:58:28 +0100
commite83a08d795ed15c7cd9378dfa75b1c7b388a80f7 (patch)
treed11c5a6dfa49cc0efbb80b4b99ea7767bc2b768c /synapse/handlers/room.py
parentMerge pull request #1177 from matrix-org/paul/standard-metric-names (diff)
parentActually use the new function (diff)
downloadsynapse-e83a08d795ed15c7cd9378dfa75b1c7b388a80f7.tar.xz
Merge pull request #1178 from matrix-org/erikj/current_room_token
Fix incredibly slow back pagination query
Diffstat (limited to 'synapse/handlers/room.py')
-rw-r--r--synapse/handlers/room.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/synapse/handlers/room.py b/synapse/handlers/room.py
index a7f533f7be..59e4d1cd15 100644
--- a/synapse/handlers/room.py
+++ b/synapse/handlers/room.py
@@ -475,8 +475,11 @@ class RoomEventSource(object):
 
         defer.returnValue((events, end_key))
 
-    def get_current_key(self, direction='f'):
-        return self.store.get_room_events_max_id(direction)
+    def get_current_key(self):
+        return self.store.get_room_events_max_id()
+
+    def get_current_key_for_room(self, room_id):
+        return self.store.get_room_events_max_id(room_id)
 
     @defer.inlineCallbacks
     def get_pagination_rows(self, user, config, key):