element-hq / synapse

Synapse: Matrix homeserver written in Python/Twisted.
https://element-hq.github.io/synapse
GNU Affero General Public License v3.0
1.46k stars 173 forks source link

Add an Admin API to forget all rooms with 0 local members #17812

Open Twi1ightSparkle opened 1 week ago

Twi1ightSparkle commented 1 week ago

Description:

Since forget_rooms_on_leave defaults to false, enabling forgotten_room_retention_period on your server may leave you with a bunch of old un-forgotten rooms on your server. An Admin API to forget all local rooms with 0 local members would solve this and allow you to easily clean up old unused rooms after enabling forget_rooms_on_leave and/or forgotten_room_retention_period.

The alternative would be to manually look over all the rooms on your server and manually deleting all rooms with 0 local members. But this can be tedious if you have lots of rooms or users.

Twi1ightSparkle commented 1 week ago

Also because of https://github.com/matrix-org/matrix-react-sdk/pull/12286, there is currently no way for users to manually forget rooms they have left using Element

daedric7 commented 1 week ago

While this issue is up, know that there are tools to help you with that :)