summary refs log tree commit diff
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2018-05-08 16:15:07 +0100
committerErik Johnston <erik@matrix.org>2018-05-08 16:15:25 +0100
commit274b8c6025e15eede0137bcb6a73ac00bf370ee8 (patch)
treecbcab8b55b21a8ee98d37ad7560374b7266be6c0
parentSplit paginate_room_events storage function (diff)
downloadsynapse-274b8c6025e15eede0137bcb6a73ac00bf370ee8.tar.xz
Only fetch required fields from database
-rw-r--r--synapse/storage/stream.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/synapse/storage/stream.py b/synapse/storage/stream.py
index b57a8a7ef6..d3adb0bf37 100644
--- a/synapse/storage/stream.py
+++ b/synapse/storage/stream.py
@@ -796,7 +796,8 @@ class StreamWorkerStore(EventsWorkerStore, SQLBaseStore):
             limit_str = ""
 
         sql = (
-            "SELECT * FROM events"
+            "SELECT event_id, topological_ordering, stream_ordering"
+            " FROM events"
             " WHERE outlier = ? AND room_id = ? AND %(bounds)s"
             " ORDER BY topological_ordering %(order)s,"
             " stream_ordering %(order)s %(limit)s"