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

S3 HeadObject returns ReplicationStatus=COMPLETED while in API you have ReplicationStatus.COMPLETE #4152

Closed
lukaszlenart opened this issue Jun 29, 2023 · 3 comments
Labels
bug This issue is a bug. service-api This issue is due to a problem in a service API, not the SDK implementation.

Comments

@lukaszlenart
Copy link

lukaszlenart commented Jun 29, 2023

Describe the bug

Setup a S3 bucket replication, request status of a file in the origin bucket, you will get the following response

HeadObjectResponse(..., Metadata={}, ReplicationStatus=COMPLETED)

the problem is when you use ReplicationStatus enum there is COMPLETE instead of COMPLETED and you are ending with UNKNOWN_TO_SDK_VERSION state.

Expected Behavior

SDK should match the status returned by the endpoint

Current Behavior

ReplicationStatus.COMPLETE != ReplicationStatus=COMPLETED

Reproduction Steps

You must have a replication between S3 buckets defined, put a file in one bucket and check its status using

HeadObjectRequest.builder().bucket(bucketNameStr).key(fileKeyStr).build()
val response = s3Client.headObject(request)

Possible Solution

No response

Additional Information/Context

No response

AWS Java SDK version used

2.20.92

JDK version used

17

Operating System and version

macOS Ventura 13.4.1 (22F82)

@lukaszlenart
Copy link
Author

Here is the bug, supposed to be COMPLETED

lukaszlenart added a commit to lukaszlenart/aws-sdk-java-v2 that referenced this issue Jun 29, 2023
@debora-ito debora-ito added service-api This issue is due to a problem in a service API, not the SDK implementation. and removed needs-triage This issue or PR still needs to be triaged. labels Jun 30, 2023
@debora-ito
Copy link
Member

@lukaszlenart thank you for the PR but we won't be able to merge it.

Any change in the service model must be made upstream, so that all the SDKs (not only Java) can benefit from the fix. Each service is responsible for maintaining their model, so this must be fixed by the S3 team.

This was previously reported here: aws/aws-sdk#242 - please track that link for updates.

@github-actions
Copy link

⚠️COMMENT VISIBILITY WARNING⚠️

Comments on closed issues are hard for our team to see.
If you need more assistance, please open a new issue that references this one.
If you wish to keep having a conversation with other community members under this issue feel free to do so.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue is a bug. service-api This issue is due to a problem in a service API, not the SDK implementation.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants