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

Add copy to S3Template #1157

Open
zambrinf opened this issue May 25, 2024 · 2 comments
Open

Add copy to S3Template #1157

zambrinf opened this issue May 25, 2024 · 2 comments
Labels
component: s3 S3 integration related issue status: waiting-for-feedback Waiting for feedback from issuer type: enhancement Smaller enhancement in existing integration

Comments

@zambrinf
Copy link

zambrinf commented May 25, 2024

Type: Feature

When uploading a gzip file via another API it doesn't create the "Content-Encoding" metadata automatically, so I have to copy the file adding the contentEncoding parameter using S3Client.

Describe the solution you'd like
Add a method to execute Copy on S3Template passing the source/destination buckets and keys and possibly the Content-Encoding parameter.

Describe alternatives you've considered
Alternative is using S3Client directly, but more verbose.

May I try to work on this?

@maciejwalkowiak
Copy link
Contributor

@zambrinf thanks for reporting. Before submitting a PR, can you propose how the API will look like?

@maciejwalkowiak maciejwalkowiak added component: s3 S3 integration related issue type: enhancement Smaller enhancement in existing integration status: waiting-for-feedback Waiting for feedback from issuer labels Sep 19, 2024
@zambrinf
Copy link
Author

zambrinf commented Sep 19, 2024

@maciejwalkowiak something like String sourceBucket, String sourceKey, String destBucket, String destKey, Map<String, String> metadata, but for the content-encoding you can't just pass as metadata, you need to use CopyObjectRequest.Builder's .contentEncoding("someEncoding") method. Would be good if it's extendable to other parameters like contentType, contentLanguage, etc, probably checking if they are present and then setting in the builder. Maybe another Map parameter with keys being an Enum? Any thoughts?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: s3 S3 integration related issue status: waiting-for-feedback Waiting for feedback from issuer type: enhancement Smaller enhancement in existing integration
Projects
None yet
Development

No branches or pull requests

2 participants