Skip to content

Commit a285fe0

Browse files
erikjohnstonrichvdh
authored andcommitted
Add timeout to ResponseCache of /public_rooms
1 parent 516f884 commit a285fe0

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

synapse/handlers/room_list.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,12 @@
4646
class RoomListHandler(BaseHandler):
4747
def __init__(self, hs):
4848
super(RoomListHandler, self).__init__(hs)
49-
self.response_cache = ResponseCache(hs, "room_list")
50-
self.remote_response_cache = ResponseCache(hs, "remote_room_list",
51-
timeout_ms=30 * 1000)
49+
self.response_cache = ResponseCache(
50+
hs, "room_list", timeout_ms=10 * 60 * 1000,
51+
)
52+
self.remote_response_cache = ResponseCache(
53+
hs, "remote_room_list", timeout_ms=30 * 1000,
54+
)
5255

5356
def get_local_public_room_list(self, limit=None, since_token=None,
5457
search_filter=None,

0 commit comments

Comments
 (0)