-
Notifications
You must be signed in to change notification settings - Fork 1.2k
S3 Directory Support #3304
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
base: version-3
Are you sure you want to change the base?
S3 Directory Support #3304
Conversation
|
Detected 1 possible performance regressions:
|
| # * `:completed_downloads` - Number of objects successfully downloaded | ||
| # * `:failed_downloads` - Number of objects that failed to download | ||
| # * `:errors` - Array of errors for failed downloads (only present when failures occur) | ||
| def download_directory(destination, bucket:, **options) |
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 need to allow for setting a custom thread for executor here. Same goes for uploader.
| request_abort unless opts[:ignore_failure] | ||
| end | ||
|
|
||
| def process_download_queue(producer, downloader, opts) |
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.
In a situation where we need to raise, I decided against doing @queue_executor.kill since there might be work in-flight that hangs. It would be best to exit gracefully and the bubbles up to raise within #build_results
| raise ArgumentError, 'Invalid directory' unless Dir.exist?(source_directory) | ||
|
|
||
| uploader = FileUploader.new( | ||
| multipart_threshold: opts.delete(:multipart_threshold), |
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.
Self-reminder to documentation this at TransferManager#upload_directory
I need to take a look at other params available on FileUploader and FileDownloader level but I'm concerned about overlapped params if it occurs.
Adds directory upload/download to Transfer Manager.
upload_directorydownload_directoryBy submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
To make sure we include your contribution in the release notes, please make sure to add description entry for your changes in the "unreleased changes" section of the
CHANGELOG.mdfile (at corresponding gem). For the description entry, please make sure it lives in one line and starts withFeatureorIssuein the correct format.For generated code changes, please checkout below instructions first:
https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
Thank you for your contribution!