mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-02 11:26:09 -04:00
Prefill stream change caches
This commit is contained in:
parent
ebc5f00efe
commit
18579534ea
4 changed files with 52 additions and 19 deletions
|
@ -14,7 +14,6 @@
|
|||
# limitations under the License.
|
||||
|
||||
from ._base import SQLBaseStore
|
||||
from synapse.util.caches.stream_change_cache import StreamChangeCache
|
||||
from twisted.internet import defer
|
||||
|
||||
import ujson as json
|
||||
|
@ -24,14 +23,6 @@ logger = logging.getLogger(__name__)
|
|||
|
||||
|
||||
class AccountDataStore(SQLBaseStore):
|
||||
def __init__(self, hs):
|
||||
super(AccountDataStore, self).__init__(hs)
|
||||
|
||||
self._account_data_stream_cache = StreamChangeCache(
|
||||
"AccountDataAndTagsChangeCache",
|
||||
self._account_data_id_gen.get_max_token(None),
|
||||
max_size=10000,
|
||||
)
|
||||
|
||||
def get_account_data_for_user(self, user_id):
|
||||
"""Get all the client account_data for a user.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue