Skip to content

Commit

Permalink
fix(core): S3 multipart uploads does not set file metadata (#5430)
Browse files Browse the repository at this point in the history
Fixed: S3 multipart uploads does not set file metadata

Co-authored-by: catcatmu <3618380+catcatmu@users.noreply.github.com>
  • Loading branch information
catcatmu and catcatmu authored Dec 19, 2024
1 parent a9d0ec6 commit f0ace56
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions core/src/services/s3/core.rs
Original file line number Diff line number Diff line change
Expand Up @@ -666,6 +666,13 @@ impl S3Core {
req = req.header(HeaderName::from_static(constants::X_AMZ_STORAGE_CLASS), v);
}

// Set user metadata headers.
if let Some(user_metadata) = args.user_metadata() {
for (key, value) in user_metadata {
req = req.header(format!("{X_AMZ_META_PREFIX}{key}"), value)
}
}

// Set SSE headers.
let req = self.insert_sse_headers(req, true);

Expand Down

0 comments on commit f0ace56

Please sign in to comment.