summary refs log tree commit diff
path: root/synapse/storage
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2016-01-28 18:26:16 +0000
committerErik Johnston <erik@matrix.org>2016-01-28 18:26:16 +0000
commitf3af1840cbd58a769a856c65de35fba912802e4d (patch)
treee921526099985bc8e8bf52404dd757da8c20e662 /synapse/storage
parentPrune on fetching (diff)
parentFix test (diff)
downloadsynapse-f3af1840cbd58a769a856c65de35fba912802e4d.tar.xz
Merge pull request #537 from matrix-org/erikj/cache_filters
Cache user filters.
Diffstat (limited to 'synapse/storage')
-rw-r--r--synapse/storage/filtering.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/synapse/storage/filtering.py b/synapse/storage/filtering.py
index f8fc9bdddc..5248736816 100644
--- a/synapse/storage/filtering.py
+++ b/synapse/storage/filtering.py
@@ -16,12 +16,13 @@
 from twisted.internet import defer
 
 from ._base import SQLBaseStore
+from synapse.util.caches.descriptors import cachedInlineCallbacks
 
 import simplejson as json
 
 
 class FilteringStore(SQLBaseStore):
-    @defer.inlineCallbacks
+    @cachedInlineCallbacks(num_args=2)
     def get_user_filter(self, user_localpart, filter_id):
         def_json = yield self._simple_select_one_onecol(
             table="user_filters",