diff options
author | Erik Johnston <erik@matrix.org> | 2018-03-01 14:16:02 +0000 |
---|---|---|
committer | Erik Johnston <erik@matrix.org> | 2018-03-01 14:17:53 +0000 |
commit | a9a2d66cdd0abc2339641808698e63cb06c4a038 (patch) | |
tree | 152b1154af5178350374f06c59a185838b1a108d /synapse/storage/signatures.py | |
parent | Merge pull request #2920 from matrix-org/erikj/retry_send_event (diff) | |
download | synapse-a9a2d66cdd0abc2339641808698e63cb06c4a038.tar.xz |
Split out SignatureStore and EventFederationStore
Diffstat (limited to 'synapse/storage/signatures.py')
-rw-r--r-- | synapse/storage/signatures.py | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/synapse/storage/signatures.py b/synapse/storage/signatures.py index 67d5d9969a..e6eeb1b641 100644 --- a/synapse/storage/signatures.py +++ b/synapse/storage/signatures.py @@ -22,9 +22,7 @@ from synapse.crypto.event_signing import compute_event_reference_hash from synapse.util.caches.descriptors import cached, cachedList -class SignatureStore(SQLBaseStore): - """Persistence for event signatures and hashes""" - +class SignatureWorkerStore(SQLBaseStore): @cached() def get_event_reference_hash(self, event_id): return self._get_event_reference_hashes_txn(event_id) @@ -74,6 +72,10 @@ class SignatureStore(SQLBaseStore): txn.execute(query, (event_id, )) return {k: v for k, v in txn} + +class SignatureStore(SignatureWorkerStore): + """Persistence for event signatures and hashes""" + def _store_event_reference_hashes_txn(self, txn, events): """Store a hash for a PDU Args: |