-
Notifications
You must be signed in to change notification settings - Fork 8
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
DDS-1680: AddFailedFiles endpoint to insert files if failed #1472
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Codecov Report
@@ Coverage Diff @@
## dev #1472 +/- ##
==========================================
+ Coverage 90.32% 91.17% +0.85%
==========================================
Files 29 29
Lines 4484 4542 +58
==========================================
+ Hits 4050 4141 +91
+ Misses 434 401 -33
|
Co-authored-by: Ina Odén Österbo <[email protected]>
Co-authored-by: Ina Odén Österbo <[email protected]>
i-oden
reviewed
Oct 31, 2023
i-oden
reviewed
Oct 31, 2023
i-oden
changed the title
Add AddFailedFiles endpoint
DDS-1680: AddFailedFiles endpoint to insert files if failed
Oct 31, 2023
rv0lt
reviewed
Oct 31, 2023
rv0lt
reviewed
Nov 1, 2023
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.
The only comment I see is the Garbage collector thing :)
i-oden
reviewed
Nov 2, 2023
rv0lt
approved these changes
Nov 2, 2023
i-oden
approved these changes
Nov 2, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Read this before submitting the PR
If there is a field which you are unsure about, enter the edit mode of this description or go to the PR template; There are invisible comments providing descriptions which may be of help.
1. Description / Summary
On data upload, it can happen that some files uploaded to S3 are not added to the DB (due to failed API request or DB lock). In such cases, DDS CLI creates a log file containing the failed files, which is supposed to be passed to the
update-uploaded-file
flask command for adding the files in the DB. This change creates an endpoint for updating the failed files upon a request from DDS CLI.Tested manually in the following way:
data_putter.py
,def put
, line 376 (in the try-except block), I added:data_putter.py
,def add_file_db
, line 431 (in the try-except block), I added:dds data put -p [project] -s tests
--overwrite
--overwrite
2. Jira task / GitHub issue
DDS-1529
3. Type of change
What type of change(s) does the PR contain?
Check the relevant boxes below. For an explanation of the different sections, enter edit mode of this PR description template.
4. Additional information
master
branch: _If checked, read the release instructions5. Actions / Scans
Check the boxes when the specified checks have passed.
For information on what the different checks do and how to fix it if they're failing, enter edit mode of this description or go to the PR template.