Move DB pool and helper functions into dedicated Database class

This commit is contained in:
Erik Johnston 2019-12-04 13:52:46 +00:00
parent ddbbfc9512
commit 756d4942f5
62 changed files with 2377 additions and 2295 deletions

View file

@ -48,7 +48,7 @@ class SignatureWorkerStore(SQLBaseStore):
for event_id in event_ids
}
return self.runInteraction("get_event_reference_hashes", f)
return self.db.runInteraction("get_event_reference_hashes", f)
@defer.inlineCallbacks
def add_event_hashes(self, event_ids):
@ -98,4 +98,4 @@ class SignatureStore(SignatureWorkerStore):
}
)
self.simple_insert_many_txn(txn, table="event_reference_hashes", values=vals)
self.db.simple_insert_many_txn(txn, table="event_reference_hashes", values=vals)