ITADN

MultipartCopy Fails with the presence of Storage Class Header

#1245ClosedLuka-J9 创建于 2025-10-16
L
Luka-J9commented
An extension of: https://github.com/apache/pekko-connectors/pull/81 When `x-amz-storage-class` is manually added to the headers of a `multipartCopy` request the resulting call fails with a ``` S3Exception: The specified header is not valid in this context ``` I believe the fix is the same as what was in the original PR, however it was not done for the CopyPart Changing the code to follow the pattern of the linked PR resolves the issue - however it's worth noting that this does come at the expense of other legitimate fields like `x-amz-request-payer` [See AWS docs for valid headers](https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html#API_UploadPartCopy_RequestSyntax) It seems that we would need to filter out the headers that are not in this list, rather than only include the SSE headers. Happy to contribute - although I'm not exactly sure what would be the pattern to employ to only allow for a subset of headers
关闭于 2025-11-28 5 条评论