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

CopyObject does not support x-amz-metadata-directive header to replace metadata #44

Closed
halkyon opened this issue Oct 7, 2021 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@halkyon
Copy link
Contributor

halkyon commented Oct 7, 2021

When copying an object, Gateway-ST and MT currently copy over the metadata, but do not respect the x-amz-metadata-directive header being set to "REPLACE", which you can use to indicate that the metadata should be set to what was provided in the CopyObject request, instead of copying it from the original object.

The default is copy metadata if no header is specified. See https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html

I put together a WIP: https://review.dev.storj.io/c/storj/gateway/+/5927

@halkyon
Copy link
Contributor Author

halkyon commented Oct 8, 2021

It turns out this was slightly more complicated than originally anticipated, due to the interplay between metadata and tagging in the way we store the metadata. I've updated https://review.dev.storj.io/c/storj/gateway/+/5927 with latest work, but it needs tests.

@wthorp wthorp added the bug Something isn't working label Oct 12, 2021
@halkyon halkyon self-assigned this Oct 17, 2021
@halkyon
Copy link
Contributor Author

halkyon commented Oct 18, 2021

Closed by storj/gateway-st@ff10634

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants