Skip to content
This repository was archived by the owner on Apr 26, 2024. It is now read-only.

Commit 3049943

Browse files
committed
Drop groups/communities tables.
1 parent f7baffd commit 3049943

File tree

4 files changed

+36
-21
lines changed

4 files changed

+36
-21
lines changed

changelog.d/12967.removal

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Drop tables used for groups/communities.

synapse/_scripts/synapse_port_db.py

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -167,22 +167,6 @@
167167
"ui_auth_sessions",
168168
"ui_auth_sessions_credentials",
169169
"ui_auth_sessions_ips",
170-
# Groups/communities is no longer supported.
171-
"group_attestations_remote",
172-
"group_attestations_renewals",
173-
"group_invites",
174-
"group_roles",
175-
"group_room_categories",
176-
"group_rooms",
177-
"group_summary_roles",
178-
"group_summary_room_categories",
179-
"group_summary_rooms",
180-
"group_summary_users",
181-
"group_users",
182-
"groups",
183-
"local_group_membership",
184-
"local_group_updates",
185-
"remote_profile_cache",
186170
}
187171

188172

synapse/storage/schema/__init__.py

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
# See the License for the specific language governing permissions and
1313
# limitations under the License.
1414

15-
SCHEMA_VERSION = 71 # remember to update the list below when updating
15+
SCHEMA_VERSION = 72 # remember to update the list below when updating
1616
"""Represents the expectations made by the codebase about the database schema
1717
1818
This should be incremented whenever the codebase changes its requirements on the
@@ -75,10 +75,9 @@
7575

7676

7777
SCHEMA_COMPAT_VERSION = (
78-
# We now assume that `device_lists_changes_in_room` has been filled out for
79-
# recent device_list_updates.
80-
# ... and that `application_services_state.last_txn` is not used.
81-
69
78+
# We now assume that `event_edges.room_id` is unused
79+
# ... and that tables related to groups are unused.
80+
71
8281
)
8382
"""Limit on how far the synapse codebase can be rolled back without breaking db compat
8483
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
/* Copyright 2022 The Matrix.org Foundation C.I.C
2+
*
3+
* Licensed under the Apache License, Version 2.0 (the "License");
4+
* you may not use this file except in compliance with the License.
5+
* You may obtain a copy of the License at
6+
*
7+
* http://www.apache.org/licenses/LICENSE-2.0
8+
*
9+
* Unless required by applicable law or agreed to in writing, software
10+
* distributed under the License is distributed on an "AS IS" BASIS,
11+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
* See the License for the specific language governing permissions and
13+
* limitations under the License.
14+
*/
15+
16+
-- Remove the tables which powered the unspecced groups/communities feature.
17+
DROP TABLE IF EXISTS group_attestations_remote;
18+
DROP TABLE IF EXISTS group_attestations_renewals;
19+
DROP TABLE IF EXISTS group_invites;
20+
DROP TABLE IF EXISTS group_roles;
21+
DROP TABLE IF EXISTS group_room_categories;
22+
DROP TABLE IF EXISTS group_rooms;
23+
DROP TABLE IF EXISTS group_summary_roles;
24+
DROP TABLE IF EXISTS group_summary_room_categories;
25+
DROP TABLE IF EXISTS group_summary_rooms;
26+
DROP TABLE IF EXISTS group_summary_users;
27+
DROP TABLE IF EXISTS group_users;
28+
DROP TABLE IF EXISTS groups;
29+
DROP TABLE IF EXISTS local_group_membership;
30+
DROP TABLE IF EXISTS local_group_updates;
31+
DROP TABLE IF EXISTS remote_profile_cache;

0 commit comments

Comments
 (0)