diff options
author | Richard van der Hoff <1389908+richvdh@users.noreply.github.com> | 2020-05-01 18:05:58 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-05-01 18:05:58 +0100 |
commit | 97ef1471c67bc4f736d758f2e4f99178bd01d469 (patch) | |
tree | c789df066b0be21784c9a19a698874b007b30fc6 /synapse/storage | |
parent | Thread through instance name to replication client. (#7369) (diff) | |
download | synapse-97ef1471c67bc4f736d758f2e4f99178bd01d469.tar.xz |
Wait for current_state_events_membership before populate_stats_process_rooms (#7387)
populate_stats_process_rooms was added in #5971 / v1.4.0; current_state_events_membership was added in #5706 / v1.3.0. Fixes #7380.
Diffstat (limited to 'synapse/storage')
-rw-r--r-- | synapse/storage/data_stores/main/schema/delta/56/stats_separated.sql | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/synapse/storage/data_stores/main/schema/delta/56/stats_separated.sql b/synapse/storage/data_stores/main/schema/delta/56/stats_separated.sql index 163529c071..bbdde121e8 100644 --- a/synapse/storage/data_stores/main/schema/delta/56/stats_separated.sql +++ b/synapse/storage/data_stores/main/schema/delta/56/stats_separated.sql @@ -35,9 +35,13 @@ DELETE FROM background_updates WHERE update_name IN ( 'populate_stats_cleanup' ); +-- this relies on current_state_events.membership having been populated, so add +-- a dependency on current_state_events_membership. INSERT INTO background_updates (update_name, progress_json, depends_on) VALUES - ('populate_stats_process_rooms', '{}', ''); + ('populate_stats_process_rooms', '{}', 'current_state_events_membership'); +-- this also relies on current_state_events.membership having been populated, but +-- we get that as a side-effect of depending on populate_stats_process_rooms. INSERT INTO background_updates (update_name, progress_json, depends_on) VALUES ('populate_stats_process_users', '{}', 'populate_stats_process_rooms'); |