-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
add S3 minimum part size defined by the user #17171
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Renan Rangel <[email protected]>
Review ChecklistHello reviewers! 👋 Please follow this checklist when reviewing this Pull Request. General
Tests
Documentation
New flags
If a workflow is added or modified:
Backward compatibility
|
Signed-off-by: Renan Rangel <[email protected]>
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #17171 +/- ##
=======================================
Coverage 67.45% 67.46%
=======================================
Files 1569 1569
Lines 252229 252246 +17
=======================================
+ Hits 170150 170176 +26
+ Misses 82079 82070 -9 ☔ View full report in Codecov by Sentry. |
Signed-off-by: Renan Rangel <[email protected]>
Signed-off-by: Renan Rangel <[email protected]>
44ede6d
to
807c22b
Compare
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. Just a couple of minor comments.
@@ -195,6 +195,7 @@ Flags: | |||
--remote_operation_timeout duration time to wait for a remote operation (default 15s) | |||
--restart_before_backup Perform a mysqld clean/full restart after applying binlogs, but before taking the backup. Only makes sense to work around xtrabackup bugs. | |||
--s3_backup_aws_endpoint string endpoint of the S3 backend (region must be provided). | |||
--s3_backup_aws_minimum_partsize int Minimum part size to use (default 5242880) |
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.
Nit, but we use min
in other existing flags so we can shorten this one as well. New flags should also use dashes rather than underscores as we want to transition to the latter for everything.
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.
Since this flag is part of a group... we may actually just want to keep them all uniform...
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 can change it to min
, but do let me know if the preferred is to use the dashes instead of underscores for it :)
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 would favor uniformity for this config group over moving to dashes, and move these all together.
} | ||
|
||
if minimumPartSize != 0 && partSizeBytes < minimumPartSize { | ||
if minimumPartSize > 1024*1024*1024*5 || minimumPartSize < 1024*1024*5 { // 5GiB and 5MiB respectively |
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.
Where do these min and max values come from? I would hope that there are consts we can use instead?
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.
that's a great point. for the minimum, the SDK does define it, so we could use manager.MinUploadPartSize
, but I don't see anything for the max. I will take a better look when I update the code for the flag change mentioned above, but we can at least change that one
Description
This adds a new parameter to allow the operator to specify a minimum part size for the S3 uploads.
Related Issue(s)
fixes #17175
Checklist
Deployment Notes