xichen01 commented on code in PR #4188:
URL: https://github.com/apache/ozone/pull/4188#discussion_r1089167889
##########
hadoop-ozone/client/src/main/java/org/apache/hadoop/ozone/client/OzoneKey.java:
##########
@@ -45,6 +45,10 @@ public class OzoneKey {
* Name of the Key.
*/
private final String name;
+ /**
+ * Name of the Key owner.
+ */
+ private final String ownerName;
Review Comment:
I will change this, but my feedback may be slow, since I am still in holiday
until 30th Jan.
##########
hadoop-ozone/s3gateway/src/test/java/org/apache/hadoop/ozone/s3/endpoint/TestBucketList.java:
##########
@@ -108,6 +109,37 @@ public void listSubDir() throws OS3Exception, IOException {
}
+ @Test
+ public void listObjectOwner() throws OS3Exception, IOException {
+
+ UserGroupInformation user1 = UserGroupInformation
+ .createUserForTesting("user1", new String[] {"user1"});
+ UserGroupInformation user2 = UserGroupInformation
+ .createUserForTesting("user2", new String[] {"user2"});
+
+ BucketEndpoint getBucket = new BucketEndpoint();
+ OzoneClient client = new OzoneClientStub();
+ client.getObjectStore().createS3Bucket("b1");
+ OzoneBucket bucket = client.getObjectStore().getS3Bucket("b1");
+
+ UserGroupInformation.setLoginUser(user1);
Review Comment:
For s3g, if you put an object, the object's owner will be the AWS "logged
in" user, not the S3 Gateway user. this test only for `Ozone client`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]