1
0
Fork 0
mirror of https://github.com/element-hq/synapse.git synced 2025-03-20 06:34:47 +00:00
synapse/tests/rest/admin
Mathieu Velten b3ba501c52
Properly purge state groups tables when purging a room (#18024)
Currently purging a complex room can lead to a lot of orphaned rows left
behind in the state groups tables.
It seems it is because we are loosing track of state groups sometimes.

This change uses the `room_id` indexed column of `state_groups` table to
decide what to delete instead of doing an indirection through
`event_to_state_groups`.

Related to https://github.com/element-hq/synapse/issues/3364.

### Pull Request Checklist

* [x] Pull request is based on the develop branch
* [x] Pull request includes a [changelog
file](https://element-hq.github.io/synapse/latest/development/contributing_guide.html#changelog).
* [x] [Code
style](https://element-hq.github.io/synapse/latest/code_style.html) is
correct
(run the
[linters](https://element-hq.github.io/synapse/latest/development/contributing_guide.html#run-the-linters))

---------

Co-authored-by: Erik Johnston <erikj@jki.re>
2025-01-06 15:32:18 +00:00
..
__init__.py Update license headers 2023-11-21 15:29:58 -05:00
test_admin.py Enable authenticated media by default (#17889) 2024-11-20 14:48:22 +00:00
test_background_updates.py Correctly mention previous copyright (#16820) 2024-01-23 11:26:48 +00:00
test_device.py Correctly mention previous copyright (#16820) 2024-01-23 11:26:48 +00:00
test_event_reports.py Add some useful endpoints to Admin API (#17948) 2024-12-16 13:27:34 -06:00
test_federation.py Fix typo in error message when a media ID isn't known (#17865) 2024-11-12 16:41:14 +00:00
test_jwks.py Correctly mention previous copyright (#16820) 2024-01-23 11:26:48 +00:00
test_media.py Enable authenticated media by default (#17889) 2024-11-20 14:48:22 +00:00
test_registration_tokens.py Correctly mention previous copyright (#16820) 2024-01-23 11:26:48 +00:00
test_room.py Properly purge state groups tables when purging a room (#18024) 2025-01-06 15:32:18 +00:00
test_server_notice.py Format files with Ruff (#17643) 2024-09-02 12:39:04 +01:00
test_statistics.py Fix typo in error message when a media ID isn't known (#17865) 2024-11-12 16:41:14 +00:00
test_user.py Add a test to verify remote user messages can be redacted via admin api redaction endpoint if requester is admin in room (#18043) 2025-01-03 12:52:42 +00:00
test_username_available.py Correctly mention previous copyright (#16820) 2024-01-23 11:26:48 +00:00