Sync ignored table names in synapse_port_db to current database schema (#7717)

This commit is contained in:
Patrick Cloke 2020-06-23 07:33:25 -04:00 committed by GitHub
parent 95e41f368b
commit 24110255cd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 13 additions and 4 deletions

1
changelog.d/7717.bugfix Normal file
View File

@ -0,0 +1 @@
Fix the tables ignored by `synapse_port_db` to be in sync the current database schema.

View File

@ -129,10 +129,20 @@ APPEND_ONLY_TABLES = [
IGNORED_TABLES = {
# We don't port these tables, as they're a faff and we can regenerate
# them anyway.
"user_directory",
"user_directory_search",
"users_who_share_rooms",
"users_in_pubic_room",
"user_directory_search_content",
"user_directory_search_docsize",
"user_directory_search_segdir",
"user_directory_search_segments",
"user_directory_search_stat",
"user_directory_search_pos",
"users_who_share_private_rooms",
"users_in_public_room",
# UI auth sessions have foreign keys so additional care needs to be taken,
# the sessions are transient anyway, so ignore them.
"ui_auth_sessions",
"ui_auth_sessions_credentials",
}
@ -301,8 +311,6 @@ class Porter(object):
return
if table in IGNORED_TABLES:
# We don't port these tables, as they're a faff and we can regenerate
# them anyway.
self.progress.update(table, table_size) # Mark table as done
return