uploadobjusingmpu-ruby-sdk
Using the AWS SDK for Ruby for Multipart Upload
The AWS SDK for Ruby version 3 supports Amazon S3 multipart uploads in two ways. For the first option, you can use managed file uploads. For more information, see Uploading Files to Amazon S3 in the AWS Developer Blog. Managed file uploads are the recommended method for uploading files to a bucket. They provides the following benefits:
- Manages multipart uploads for objects larger than 15MB.
- Correctly opens files in binary mode to avoid encoding issues.
- Uses multiple threads for uploading parts of large objects in parallel.
Alternatively, you can use the following multipart upload client operations directly:
- create_multipart_upload โ Initiates a multipart upload and returns an upload ID.
- upload_part โ Uploads a part in a multipart upload.
- upload_part_copy โ Uploads a part by copying data from an existing object as data source.
- complete_multipart_upload โ Completes a multipart upload by assembling previously uploaded parts.
- abort_multipart_upload โ Aborts a multipart upload.
For more information, see Using the AWS SDK for Ruby - Version 3.