rich7420 commented on code in PR #11479:
URL: https://github.com/apache/ozone/pull/11479#discussion_r4432498397


##########
hadoop-ozone/client/src/main/java/org/apache/hadoop/ozone/client/rpc/RpcClient.java:
##########
@@ -3162,7 +3172,7 @@ public Map<String, String> getObjectTagging(
       throw new IOException("OzoneManager does not support S3 object tagging 
API");
     }
 
-    boolean assumeS3Context = volumeName == null && resolveS3VolumeOnOm;
+    boolean assumeS3Context = volumeName == null;

Review Comment:
   I also reproduced this in `getBucketDetails` with a non-S3G client and a 
mock older OM: it returns the bucket from `s3v` even when `GetS3VolumeContext` 
points elsewhere. Could we keep the fallback for direct callers too?



##########
hadoop-ozone/s3gateway/src/main/java/org/apache/hadoop/ozone/s3/endpoint/S3RequestContext.java:
##########
@@ -59,13 +59,20 @@ OzoneVolume getVolume() throws IOException {
 
   OzoneBucket getBucket(String name) throws IOException {
     if (bucket == null) {
-      bucket = getVolume().getBucket(name);
+      bucket = endpoint.getClientProtocol().getBucketDetails(null, name);

Review Comment:
   nit: Could we reuse the cached volume here? `BucketAclHandler` calls 
`getVolume()` first, so the old-OM fallback ends up calling 
`GetS3VolumeContext` a second time.



-- 
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]

Reply via email to