MatrixSynapse/synapse/storage
Andrew Morgan 0a363f9ca4
Remove cache for get_shared_rooms_for_users (#9416)
This PR remove the cache for the `get_shared_rooms_for_users` storage method (the db method driving the experimental "what rooms do I share with this user?" feature: [MSC2666](https://github.com/matrix-org/matrix-doc/pull/2666)). Currently subsequent requests to the endpoint will return the same result, even if your shared rooms with that user have changed.

The cache was added in https://github.com/matrix-org/synapse/pull/7785, but we forgot to ensure it was invalidated appropriately.

Upon attempting to invalidate it, I found that the cache had to be entirely invalidated whenever a user (remote or local) joined or left a room. This didn't make for a very useful cache, especially for a function that may or may not be called very often. Thus, I've opted to remove it instead of invalidating it.
2021-02-22 16:52:45 +00:00
..
databases Remove cache for get_shared_rooms_for_users (#9416) 2021-02-22 16:52:45 +00:00
engines Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
schema
util Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
__init__.py Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
_base.py Add additional type hints to the storage module. (#8980) 2020-12-30 08:09:53 -05:00
background_updates.py Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
database.py Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
keys.py Add additional type hints to the storage module. (#8980) 2020-12-30 08:09:53 -05:00
persist_events.py Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
prepare_database.py Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
purge_events.py Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
push_rule.py
relations.py Add additional type hints to the storage module. (#8980) 2020-12-30 08:09:53 -05:00
roommember.py
state.py Update black, and run auto formatting over the codebase (#9381) 2021-02-16 22:32:34 +00:00
types.py Update type hints for Cursor to match PEP 249. (#9299) 2021-02-05 15:39:19 -05:00