mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-06-07 09:22:39 -04:00
Change DataStores to accept 'database' param.
This commit is contained in:
parent
f3ea2f5a08
commit
9a4fb457cf
41 changed files with 156 additions and 114 deletions
|
@ -29,6 +29,7 @@ from synapse.api.constants import EventTypes
|
|||
from synapse.api.errors import StoreError
|
||||
from synapse.storage._base import SQLBaseStore
|
||||
from synapse.storage.data_stores.main.search import SearchStore
|
||||
from synapse.storage.database import Database
|
||||
from synapse.types import ThirdPartyInstanceID
|
||||
from synapse.util.caches.descriptors import cached, cachedInlineCallbacks
|
||||
|
||||
|
@ -361,8 +362,8 @@ class RoomWorkerStore(SQLBaseStore):
|
|||
|
||||
|
||||
class RoomBackgroundUpdateStore(SQLBaseStore):
|
||||
def __init__(self, db_conn, hs):
|
||||
super(RoomBackgroundUpdateStore, self).__init__(db_conn, hs)
|
||||
def __init__(self, database: Database, db_conn, hs):
|
||||
super(RoomBackgroundUpdateStore, self).__init__(database, db_conn, hs)
|
||||
|
||||
self.config = hs.config
|
||||
|
||||
|
@ -440,8 +441,8 @@ class RoomBackgroundUpdateStore(SQLBaseStore):
|
|||
|
||||
|
||||
class RoomStore(RoomBackgroundUpdateStore, RoomWorkerStore, SearchStore):
|
||||
def __init__(self, db_conn, hs):
|
||||
super(RoomStore, self).__init__(db_conn, hs)
|
||||
def __init__(self, database: Database, db_conn, hs):
|
||||
super(RoomStore, self).__init__(database, db_conn, hs)
|
||||
|
||||
self.config = hs.config
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue