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

Migration tool ObjectMetadata transforms #5970

Merged
merged 6 commits into from
Mar 28, 2025

Conversation

davidh44
Copy link
Contributor

@davidh44 davidh44 commented Mar 18, 2025

Motivation and Context

Add transforms for ObjectMetadata setters, moving them to PutObjectRequest, and pass ContentLength to RequestBody

ContentLength
ContentEncoding
ContentType
ContentLanguage
CacheControl
ContentDisposition
ContentMD5
SSEAlgorithm
ServerSideEncryption
SSECustomerKeyMd5
BucketKeyEnabled
HttpExpiresDate

TODO in follow up PRs:

  • Remove ObjectMetadata instantiation (transformed to HeadObjectRespoonse)

Modifications

Updated JavaIsoVisitor to JavaVisitor in S3PutObjectRequestToV2 in order to return a statement:

from:
request.setMetadata(metadata);

to:
request = request.toBuilder().setXX(..).setYY(..).build();

Testing

added end to end tests

@davidh44 davidh44 requested a review from a team as a code owner March 18, 2025 17:56
@davidh44 davidh44 enabled auto-merge March 27, 2025 22:57
Copy link

Quality Gate Failed Quality Gate failed

Failed conditions
0.0% Coverage on New Code (required ≥ 80%)
C Reliability Rating on New Code (required ≥ A)

See analysis details on SonarQube Cloud

Catch issues before they fail your Quality Gate with our IDE extension SonarQube for IDE

@davidh44 davidh44 added this pull request to the merge queue Mar 28, 2025
Merged via the queue into master with commit 3494524 Mar 28, 2025
18 of 19 checks passed
@davidh44 davidh44 deleted the hdavidh/migration-tool-objectmetadata-transform branch March 28, 2025 17:01
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.

3 participants