-
Notifications
You must be signed in to change notification settings - Fork 925
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
Create a migration function for datasource to add migrationVersion field #6025
Create a migration function for datasource to add migrationVersion field #6025
Conversation
a13d693
to
35eefe8
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #6025 +/- ##
==========================================
- Coverage 67.13% 67.13% -0.01%
==========================================
Files 3317 3318 +1
Lines 64016 64021 +5
Branches 10256 10256
==========================================
+ Hits 42979 42981 +2
- Misses 18545 18548 +3
Partials 2492 2492
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Thanks @yibow98 should we remove dummy from title. it add migration method and set the default value to 2.4.0. not truly dummy |
Done |
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.
remove dummy from code
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.
if we use '2.4.0', how could we differentiate the MDS data saved before 2.13.0 . Otherwise lgtm
The migrationVersion is the version that the saved object apply the latest migration. If there is not data schema change, then all datasource should have the migrationVersion of 2.4.0 until we have a new migration function. |
35eefe8
to
3779498
Compare
Signed-off-by: Yibo Wang <[email protected]>
3779498
to
548546b
Compare
Makes sense. Might need to fix at the root if you ever need to add multiple migrations. |
…eld (#6025) This PR is to add a migration function with version 2.4.0 for datasource to add a migrationVersion field. For more information, please refer to the RFC: #6022 Issues Resolved #6022 Signed-off-by: Yibo Wang <[email protected]> (cherry picked from commit 70adcc9) Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Description
This PR is to add a migration function with version 2.4.0 for datasource to add a migrationVersion field.
For more information, please refer to the RFC: #6022
Issues Resolved
#6022
Testing the changes
For the testing, it is included in this RFC: #6022
Check List
yarn test:jest
yarn test:jest_integration