diff options
author | Andrew Morgan <1342360+anoadragon453@users.noreply.github.com> | 2023-06-16 15:25:44 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-06-16 15:25:44 +0100 |
commit | 2ac6c3bbb535677bd62b3df425dd1755dba79b66 (patch) | |
tree | 805156a13589a16c24b5a26d63cb08a6c3715276 /synapse/storage | |
parent | push rules: fix internal conversion from _type to value (#15781) (diff) | |
download | synapse-2ac6c3bbb535677bd62b3df425dd1755dba79b66.tar.xz |
Don't always lock "user_ips" table when performing non-native upsert (#15788)
Diffstat (limited to 'synapse/storage')
-rw-r--r-- | synapse/storage/database.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/synapse/storage/database.py b/synapse/storage/database.py index 10fa6c4802..7e49ae11bc 100644 --- a/synapse/storage/database.py +++ b/synapse/storage/database.py @@ -1529,7 +1529,7 @@ class DatabasePool: # Lock the table just once, to prevent it being done once per row. # Note that, according to Postgres' documentation, once obtained, # the lock is held for the remainder of the current transaction. - self.engine.lock_table(txn, "user_ips") + self.engine.lock_table(txn, table) for keyv, valv in zip(key_values, value_values): _keys = dict(zip(key_names, keyv)) |