Skip to content
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

feat(storage): Add support to define the S3 Storage Class #2862

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

amcofi
Copy link

@amcofi amcofi commented Jun 28, 2024

Add support to define the S3 Storage Class when uploading files or streams.
Implementation is based on the existing support Server Side Encryption.

See also: https://aws.amazon.com/s3/storage-classes

  • PR title and description conform to Pull Request guidelines.

Issue #, if available:

Description of changes:

How did you test these changes?
I didn't see any tests for related functionality. I tested the storage class is set correctly when uploading to my S3 bucket from my own application.

val options = AWSS3StorageUploadInputStreamOptions.builder()
    .storageClass(aws.sdk.kotlin.services.s3.model.StorageClass.GlacierIr)
    .build()

Amplify.Storage.uploadInputStream(
    StoragePath.fromString(key),
    inputStream,
    options,
    { result -> ... },
    { error -> ... }
)

Documentation update required?

  • No
  • Yes (Please include a PR link for the documentation update)

General Checklist

  • Added Unit Tests
  • Added Integration Tests
  • Security oriented best practices and standards are followed (e.g. using input sanitization, principle of least privilege, etc)

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@amcofi amcofi requested review from a team as code owners June 28, 2024 11:41
@tylerjroach
Copy link
Member

Hi @amcofi,

Thank you for your contribution. We will take a look at the PR and get back to you!

@amcofi amcofi force-pushed the add_storageclass_option branch 2 times, most recently from 5289b8d to 7218b14 Compare July 10, 2024 14:26
@amcofi amcofi force-pushed the add_storageclass_option branch 2 times, most recently from 5172e76 to bde477c Compare July 19, 2024 09:09
@amcofi amcofi force-pushed the add_storageclass_option branch from bde477c to c8748ce Compare July 27, 2024 06:21
@amcofi amcofi force-pushed the add_storageclass_option branch from c8748ce to e898e46 Compare August 24, 2024 17:22
@amcofi amcofi force-pushed the add_storageclass_option branch 2 times, most recently from 99315b3 to 77d99d7 Compare September 12, 2024 16:45
@amcofi amcofi force-pushed the add_storageclass_option branch from 77d99d7 to 14dbb64 Compare September 15, 2024 11:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants