-
Notifications
You must be signed in to change notification settings - Fork 942
Closed
Labels
closed-for-stalenessservice-apiThis issue is due to a problem in a service API, not the SDK implementation.This issue is due to a problem in a service API, not the SDK implementation.service:s3
Description
Describe the bug
I got the issue with retrieving the acl response Owner displayName. Sometimes it returns null, sometimes not.
When execute this code:
`private static S3Client s3Client;
public static void main(String[] args) {
s3Client = S3Client.builder()
.accelerate(false)
.region(Region.AP_SOUTHEAST_2)
.crossRegionAccessEnabled(true)
.credentialsProvider(StaticCredentialsProvider.create(AwsBasicCredentials.create(getAccessKeyId(),
getSecretAccessKey())))
.build();
for (int i = 0 ; i< 10; i++) {
System.out.println(getOwner(getBucketName(), getItemName()).displayName());
}
}
public static Owner getOwner(String bucketName, String key) {
GetObjectAclRequest aclRequest = GetObjectAclRequest.builder()
.bucket(bucketName)
.key(key)
.build();
GetObjectAclResponse aclResponse = s3Client.getObjectAcl(aclRequest);
return aclResponse.owner();
}`
using amazon-s3-encryption-client-java:3.4.0
I got that response:
null
null
Real owner display name
Real owner display name
Real owner display name
null
Real owner display name
Real owner display name
Real owner display name
Real owner display name
Regression Issue
- Select this option if this issue appears to be a regression.
Expected Behavior
ACL response contains Owner display name every time
Current Behavior
Randomly s3Client.getObjectAcl(aclRequest).owner().displayName() returns null
Reproduction Steps
Execute code from the description (increase the counter in the loop if needed)
Possible Solution
No response
Additional Information/Context
No response
AWS Java SDK version used
2.31.62 and 2.34.8
JDK version used
openjdk 17.0.9 2023-10-17 LTS
Operating System and version
Windows 11
Metadata
Metadata
Assignees
Labels
closed-for-stalenessservice-apiThis issue is due to a problem in a service API, not the SDK implementation.This issue is due to a problem in a service API, not the SDK implementation.service:s3