summary refs log tree commit diff
path: root/synapse/storage/engines/sqlite.py
diff options
context:
space:
mode:
authorNick Barrett <nick@beeper.com>2022-01-25 14:14:46 +0000
committerGitHub <noreply@github.com>2022-01-25 15:14:46 +0100
commitb59d285f7c2ffce56a273686e63bcb34a461317b (patch)
tree81eefd1e1110e847bd707bcd71b0dc0eb5273889 /synapse/storage/engines/sqlite.py
parentMinor updates, and docs, for schema delta files (#11823) (diff)
downloadsynapse-b59d285f7c2ffce56a273686e63bcb34a461317b.tar.xz
Db txn set isolation level (#11799)
Co-authored-by: Brendan Abolivier <babolivier@matrix.org>
Diffstat (limited to 'synapse/storage/engines/sqlite.py')
-rw-r--r--synapse/storage/engines/sqlite.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/synapse/storage/engines/sqlite.py b/synapse/storage/engines/sqlite.py
index 70d17d4f2c..6c19e55999 100644
--- a/synapse/storage/engines/sqlite.py
+++ b/synapse/storage/engines/sqlite.py
@@ -15,6 +15,7 @@ import platform
 import struct
 import threading
 import typing
+from typing import Optional
 
 from synapse.storage.engines import BaseDatabaseEngine
 from synapse.storage.types import Connection
@@ -122,6 +123,12 @@ class Sqlite3Engine(BaseDatabaseEngine["sqlite3.Connection"]):
         # set the connection to autocommit mode.
         pass
 
+    def attempt_to_set_isolation_level(
+        self, conn: Connection, isolation_level: Optional[int]
+    ):
+        # All transactions are SERIALIZABLE by default in sqllite
+        pass
+
 
 # Following functions taken from: https://github.com/coleifer/peewee