MatrixSynapse/tests
Sean Quah 882277008c
Fix background updates failing to add unique indexes on receipts (#14453)
As part of the database migration to support threaded receipts, there is
a possible window in between
`73/08thread_receipts_non_null.sql.postgres` removing the original
unique constraints on `receipts_linearized` and `receipts_graph` and the
`reeipts_linearized_unique_index` and `receipts_graph_unique_index`
background updates from `72/08thread_receipts.sql` completing where
the unique constraints on `receipts_linearized` and `receipts_graph` are
missing. Any emulated upserts on these tables must therefore be
performed with a lock held, otherwise duplicate rows can end up in the
tables when there are concurrent emulated upserts. Fix the missing lock.

Note that emulated upserts no longer happen by default on sqlite, since
the minimum supported version of sqlite supports native upserts by
default now.

Finally, clean up any duplicate receipts that may have crept in before
trying to create the `receipts_graph_unique_index` and
`receipts_linearized_unique_index` unique indexes.

Signed-off-by: Sean Quah <seanq@matrix.org>
2022-11-16 15:01:22 +00:00
..
api Do not reject `/sync` requests with unrecognised filter fields (#14369) 2022-11-07 13:49:31 +00:00
app Use servlets for /key/ endpoints. (#14229) 2022-10-20 11:32:47 -04:00
appservice Merge branch 'master' into develop 2022-10-28 15:59:51 +01:00
config
crypto
events
federation Include heroes in partial join responses' state (#14442) 2022-11-15 17:35:19 +00:00
handlers Check appservice user interest against the local users instead of all users (`get_users_in_room` mis-use) (#13958) 2022-10-27 18:29:23 +00:00
http Making parse_server_name more consistent (#14007) 2022-10-11 12:42:11 +00:00
logging Implementation of HTTP 307 response for MSC3886 POST endpoint (#14018) 2022-10-18 15:52:25 +00:00
metrics Avoid incrementing bg process utime/stime counters by negative durations (#14323) 2022-10-31 13:02:07 +00:00
module_api
push Implementation for MSC3664: Pushrules for relations (#11804) 2022-10-25 14:38:01 +01:00
replication Merge/remove `Slaved*` stores into `WorkerStores` (#14375) 2022-11-11 10:51:49 +00:00
rest Add an Admin API endpoint for looking up users based on 3PID (#14405) 2022-11-11 15:38:17 +00:00
scripts
server_notices
state
storage Fix background updates failing to add unique indexes on receipts (#14453) 2022-11-16 15:01:22 +00:00
test_utils Support OIDC backchannel logouts (#11414) 2022-10-31 13:07:30 -04:00
util Save login tokens in database (#13844) 2022-10-26 11:45:41 +01:00
__init__.py
server.py Support OIDC backchannel logouts (#11414) 2022-10-31 13:07:30 -04:00
test_distributor.py
test_event_auth.py Rename the `EventFormatVersions` enum values so that they line up with room version numbers. (#13706) 2022-09-07 11:08:20 +01:00
test_federation.py Track when the pulled event signature fails (#13815) 2022-10-03 14:53:29 -05:00
test_mau.py
test_phone_home.py
test_rust.py Add a stub Rust crate (#12595) 2022-09-06 19:01:37 +01:00
test_server.py Implementation of HTTP 307 response for MSC3886 POST endpoint (#14018) 2022-10-18 15:52:25 +00:00
test_state.py
test_terms_auth.py
test_test_utils.py
test_types.py Fix error in `is_mine_id` when encountering a malformed ID (#13746) 2022-09-08 15:54:36 +01:00
test_visibility.py
unittest.py Persist CreateRoom events to DB in a batch (#13800) 2022-09-28 10:11:48 +00:00
utils.py Update mypy and mypy-zope, attempt 3 (#13993) 2022-09-30 17:36:28 +01:00