mirror of
https://github.com/element-hq/synapse.git
synced 2024-11-21 17:15:38 +03:00
Remove Generator
in _prune_old_outbound_device_pokes
(#17814)
Context: https://github.com/matrix-org/synapse/issues/15439 (https://github.com/element-hq/synapse/issues/15439) Also see discussion in https://github.com/element-hq/synapse/pull/17813
This commit is contained in:
parent
034d472688
commit
47fe6df013
2 changed files with 2 additions and 1 deletions
1
changelog.d/17814.bugfix
Normal file
1
changelog.d/17814.bugfix
Normal file
|
@ -0,0 +1 @@
|
||||||
|
Avoid lost data on some database query retries.
|
|
@ -1422,7 +1422,7 @@ class DeviceWorkerStore(RoomMemberWorkerStore, EndToEndKeyWorkerStore):
|
||||||
DELETE FROM device_lists_outbound_last_success
|
DELETE FROM device_lists_outbound_last_success
|
||||||
WHERE destination = ? AND user_id = ?
|
WHERE destination = ? AND user_id = ?
|
||||||
"""
|
"""
|
||||||
txn.execute_batch(sql, ((row[0], row[1]) for row in rows))
|
txn.execute_batch(sql, [(row[0], row[1]) for row in rows])
|
||||||
|
|
||||||
logger.info("Pruned %d device list outbound pokes", count)
|
logger.info("Pruned %d device list outbound pokes", count)
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue