This repository was archived by the owner on Apr 26, 2024. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
This repository was archived by the owner on Apr 26, 2024. It is now read-only.
Reintroduce DB changes from #14979, using SCHEMA_COMPAT_VERSION mechanism #15014
Copy link
Copy link
Closed
Closed
Copy link
Labels
A-DatabaseDB stuff like queries, migrations, new/remove columns, indexes, unexpected entries in the dbDB stuff like queries, migrations, new/remove columns, indexes, unexpected entries in the dbA-PerformancePerformance, both client-facing and admin-facingPerformance, both client-facing and admin-facingO-OccasionalAffects or can be seen by some users regularly or most users rarelyAffects or can be seen by some users regularly or most users rarelyS-TolerableMinor significance, cosmetic issues, low or no impact to users.Minor significance, cosmetic issues, low or no impact to users.T-EnhancementNew features, changes in functionality, improvements in performance, or user-facing enhancements.New features, changes in functionality, improvements in performance, or user-facing enhancements.
Description
The changes in #14979
ALTER TABLE current_state_events ADD COLUMN event_stream_ordering BIGINT;
ALTER TABLE local_current_membership ADD COLUMN event_stream_ordering BIGINT;
ALTER TABLE room_memberships ADD COLUMN event_stream_ordering BIGINT;
INSERT INTO background_updates (update_name, progress_json) VALUES
('populate_membership_event_stream_ordering', '{}');Problems:
- the query used by
get_ex_outlier_stream_rows_txnbecomes ambiguous: there are two columns called event_stream_ordering. Addevent_stream_orderingcolumn to membership state tables #14979 disambiguates this, but won't exist in old code. - the background update doesn't add an ordering, so it might usurp other updates in the queue.
Questions:
- does the new query assume the
populate_membership_event_stream_orderingbackground update has completed? How long do we expect it will take?
For 1.77 I
- reverted the PR: 9cd7610
- but kept in the change which disambiguates the columns in the source code anyway: f10caa7
- and bump SCHEMA_VERSION: Bump schema version #15036
For the future we should try to land the schema changes gradually (see guidance) over the next few releases.
Metadata
Metadata
Assignees
Labels
A-DatabaseDB stuff like queries, migrations, new/remove columns, indexes, unexpected entries in the dbDB stuff like queries, migrations, new/remove columns, indexes, unexpected entries in the dbA-PerformancePerformance, both client-facing and admin-facingPerformance, both client-facing and admin-facingO-OccasionalAffects or can be seen by some users regularly or most users rarelyAffects or can be seen by some users regularly or most users rarelyS-TolerableMinor significance, cosmetic issues, low or no impact to users.Minor significance, cosmetic issues, low or no impact to users.T-EnhancementNew features, changes in functionality, improvements in performance, or user-facing enhancements.New features, changes in functionality, improvements in performance, or user-facing enhancements.