diff options
author | Mark Haines <mjark@negativecurvature.net> | 2016-03-01 14:54:29 +0000 |
---|---|---|
committer | Mark Haines <mjark@negativecurvature.net> | 2016-03-01 14:54:29 +0000 |
commit | d50ca1b1edf45b630715f1847435eb493842bbdc (patch) | |
tree | 5a291e62c4615275e7fc63284b088d82f069c3a9 /synapse/storage/__init__.py | |
parent | Merge pull request #611 from matrix-org/erikj/expiring_cache_size (diff) | |
parent | Load the current id in the IdGenerator constructor (diff) | |
download | synapse-d50ca1b1edf45b630715f1847435eb493842bbdc.tar.xz |
Merge pull request #613 from matrix-org/markjh/yield
Load the current id in the IdGenerator constructor
Diffstat (limited to 'synapse/storage/__init__.py')
-rw-r--r-- | synapse/storage/__init__.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/synapse/storage/__init__.py b/synapse/storage/__init__.py index 9be1d12fac..f257721ea3 100644 --- a/synapse/storage/__init__.py +++ b/synapse/storage/__init__.py @@ -115,13 +115,13 @@ class DataStore(RoomMemberStore, RoomStore, db_conn, "presence_stream", "stream_id" ) - self._transaction_id_gen = IdGenerator("sent_transactions", "id", self) - self._state_groups_id_gen = IdGenerator("state_groups", "id", self) - self._access_tokens_id_gen = IdGenerator("access_tokens", "id", self) - self._refresh_tokens_id_gen = IdGenerator("refresh_tokens", "id", self) - self._pushers_id_gen = IdGenerator("pushers", "id", self) - self._push_rule_id_gen = IdGenerator("push_rules", "id", self) - self._push_rules_enable_id_gen = IdGenerator("push_rules_enable", "id", self) + self._transaction_id_gen = IdGenerator(db_conn, "sent_transactions", "id") + self._state_groups_id_gen = IdGenerator(db_conn, "state_groups", "id") + self._access_tokens_id_gen = IdGenerator(db_conn, "access_tokens", "id") + self._refresh_tokens_id_gen = IdGenerator(db_conn, "refresh_tokens", "id") + self._pushers_id_gen = IdGenerator(db_conn, "pushers", "id") + self._push_rule_id_gen = IdGenerator(db_conn, "push_rules", "id") + self._push_rules_enable_id_gen = IdGenerator(db_conn, "push_rules_enable", "id") events_max = self._stream_id_gen.get_max_token() event_cache_prefill, min_event_val = self._get_cache_dict( |