s3-batch-put-object

Gather many objects into a smaller number of s3:PutObject calls

Overview

A workload that creates numerous PutObject calls may be cost-inefficient due to the transactional cost of using the S3 PutObject API.

The crate provides the calling application with a similar interface to rusoto_s3, and instead of writing objects to S3 immediately, it spools them to a local tar file. The calling application can control how often the tar file containing the last batch of objects will be written to S3.

The S3BatchPutClient is safe to share across threads, and can coalesce writes from multiple concurrent threads into a single batch.

Efficient retrieval

The resulting tar files may simply be downloaded to consume each batch as a whole.

The caller of S3BatchPutClient::put_object() will also receive metadata about the location of the given object within the tar file. Once the batch has been written to S3, this metadata enables efficient access to individual objects within the batch, by allowing you to make an S3 byte-range request that retrieves a single object without needing to download the whole tar file.

Target workload

This create might help if your workload has the following attributes: