-
Notifications
You must be signed in to change notification settings - Fork 1.3k
[db-sync] Add extra columns to d_b_volume_snapshot
table to allow sync
#13348
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Add a migration to add `_lastModified` and `deleted` columns to the `d_b_volume_snapshot` table so that it can be synced by `db-sync`.
started the job as gitpod-build-af-sync-snapshots-table.6 because the annotations in the pull request description changed |
components/gitpod-db/src/tables.ts
Outdated
@@ -47,6 +47,12 @@ export class GitpodSessionTableDescriptionProvider implements TableDescriptionPr | |||
export class GitpodTableDescriptionProvider implements TableDescriptionProvider { | |||
readonly name = "gitpod"; | |||
protected readonly tables: TableDescription[] = [ | |||
{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Feels a bit risky to include this in the same PR as the migration. Are you happy with the risks involved in case the migration doesn't go through but db-sync gets rolled out?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point - I'll leave the migration + config change in this PR for ease of review but I can split it into two before merging.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've removed the db-sync
config change from this PR and I'll add it in a follow up.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
/hold for Q on risk
@andrew-farries Did you engage with @sagor999 before doing this? He's leading the PVC effort in Team Workspace. We definitely need to do this before deploying this. /hold |
I've requested a review from @sagor999. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
(I was under impression that this table already should have been db-synced but I guess it was not? So good catch! 🙏 )
99e8633
to
3430958
Compare
/unhold |
d_b_volume_snapshot
tabled_b_volume_snapshot
table to allow sync
Description
Make the
db_volume_snapshot
table able to be synced between clusters._lastModified
anddeleted
fields.Records are currently hard-deleted from this table, so the
deleted
field will not be used in practice:gitpod/components/gitpod-db/src/typeorm/workspace-db-impl.ts
Lines 776 to 779 in 99e8633
Related Issue(s)
Part of #9198
How to test
Release Notes
Documentation
Werft options:
If enabled this will build
install/preview
Valid options are
all
,workspace
,webapp
,ide