Skip to content
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

Automatic user relationship to user column migration #12102

Conversation

samwho
Copy link
Collaborator

@samwho samwho commented Oct 18, 2023

Description

Feature branch for https://linear.app/budibase/issue/BUDI-7607/migrate-user-relationship-columns-to-the-new-user-column-type.

Addresses:

Documentation

  • I have reviewed the budibase documentatation to verify if this feature requires any changes. If changes or new docs are required I have written them.

@codecov-commenter
Copy link

codecov-commenter commented Oct 18, 2023

Codecov Report

Merging #12102 (45543cb) into master (454e9cf) will decrease coverage by 1.30%.
The diff coverage is 73.96%.

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

@@            Coverage Diff             @@
##           master   #12102      +/-   ##
==========================================
- Coverage   68.49%   67.20%   -1.30%     
==========================================
  Files         594      502      -92     
  Lines       21984    19984    -2000     
  Branches     4424     4138     -286     
==========================================
- Hits        15059    13430    -1629     
+ Misses       6413     6068     -345     
+ Partials      512      486      -26     
Files Coverage Δ
packages/server/src/api/controllers/datasource.ts 75.93% <ø> (ø)
...ackages/server/src/api/controllers/public/utils.ts 66.66% <100.00%> (ø)
packages/server/src/api/controllers/row/index.ts 97.81% <100.00%> (ø)
packages/server/src/api/controllers/table/index.ts 71.56% <100.00%> (+2.41%) ⬆️
...kages/server/src/api/controllers/table/internal.ts 74.19% <ø> (+0.86%) ⬆️
packages/server/src/api/routes/table.ts 100.00% <ø> (ø)
packages/server/src/constants/index.ts 100.00% <100.00%> (ø)
...server/src/db/defaultData/datasource_bb_default.ts 48.88% <100.00%> (ø)
packages/server/src/db/linkedRows/linkUtils.ts 82.81% <100.00%> (-1.57%) ⬇️
packages/server/src/db/utils.ts 84.61% <ø> (ø)
... and 32 more

... and 96 files with indirect coverage changes

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@mike12345567 mike12345567 added the firestorm Data/Infra/Revenue Team label Oct 18, 2023
mike12345567 and others added 8 commits October 18, 2023 13:35
…di-7607-migrate-user-relationship-columns-to-the-new-user-column
…the-new-user-column' of github.com:Budibase/budibase into feature/budi-7607-migrate-user-relationship-columns-to-the-new-user-column
…di-7607-migrate-user-relationship-columns-to-the-new-user-column
@samwho samwho changed the title Migrate user relationship columns to the new user column One-to-many user column migration, backend-only Oct 19, 2023
…di-7607-migrate-user-relationship-columns-to-the-new-user-column
Copy link
Collaborator

@mike12345567 mike12345567 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great overall - just wanted to comment to say that really like the approach to the migration here - the column migrator is really nice way of handling this!

samwho and others added 25 commits October 25, 2023 16:49
…rontend expects this to be set for every table so making the type represent this correctly.
…di-7607-migrate-user-relationship-columns-to-the-new-user-column
…the-new-user-column' into feature/budi-7607-migrate-user-relationship-columns-to-the-new-user-column-4
…r-relationship-columns-to-the-new-user-column-4

Frontend changes for the user column migration work.
…new sourceType which states what source the table came from, external or internal. Don't want to keep using a type that should be static as two different things.
…r-relationship-columns-to-the-new-user-column-6

Replace several instances of `any` with `DatabaseQueryOpts`.
…required

Make sourceId property of table required (for all table types)
…di-7607-migrate-user-relationship-columns-to-the-new-user-column
Copy link
Collaborator

@mike12345567 mike12345567 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM - massive improvement to typing included here!

@mike12345567 mike12345567 marked this pull request as ready for review October 30, 2023 18:21
@samwho samwho merged commit a4ce898 into master Oct 31, 2023
10 checks passed
@samwho samwho deleted the feature/budi-7607-migrate-user-relationship-columns-to-the-new-user-column branch October 31, 2023 10:27
@github-actions github-actions bot locked and limited conversation to collaborators Oct 31, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
firestorm Data/Infra/Revenue Team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants