chihsuan commented on code in PR #11574:
URL: https://github.com/apache/ozone/pull/11574#discussion_r4398495913
##########
hadoop-ozone/client/src/main/java/org/apache/hadoop/ozone/client/protocol/ClientProtocol.java:
##########
@@ -1743,6 +1743,21 @@ default void setVerifyChecksum(boolean verifyChecksum) {
Map<String, String> getObjectTagging(String volumeName, String bucketName,
String keyName)
throws IOException;
+ /**
+ * Gets the tags for an existing key, optionally resolving the volume from
+ * the S3 request context.
+ * @param volumeName Volume name. Ignored when {@code assumeS3Context} is
true.
+ * @param bucketName Bucket name.
+ * @param keyName Key name.
+ * @param assumeS3Context Whether OM resolves the volume from the S3 request
+ * context.
+ * @return Tags for the specified key.
+ * @throws IOException If the request fails.
+ */
+ Map<String, String> getObjectTagging(String volumeName,
+ String bucketName, String keyName, boolean assumeS3Context)
+ throws IOException;
Review Comment:
Since #11757 is merged, could we switch to the `S3ClientProtocol` delegation
here?
##########
hadoop-ozone/integration-test/src/test/java/org/apache/hadoop/ozone/client/rpc/OzoneRpcClientTests.java:
##########
@@ -5664,6 +5664,34 @@ public void testGetObjectTagging(BucketLayout
bucketLayout) throws Exception {
assertThat(tagsRetrieved).containsAllEntriesOf(tags);
}
+ @Test
+ public void testGetObjectTaggingWithS3Context() throws Exception {
Review Comment:
Would it be worth adding a tenant volume case, like #11449 in
`TestMultiTenantVolume`?
--
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]