sarvekshayr commented on code in PR #11368:
URL: https://github.com/apache/ozone/pull/11368#discussion_r4242524311


##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OzoneManager.java:
##########
@@ -5494,6 +5496,13 @@ private OmBucketInfo resolveBucketLink(
       if (allowDanglingBuckets) {
         return null;
       }
+
+      if (!visited.isEmpty()
+          && (e.getResult() == VOLUME_NOT_FOUND || e.getResult() == 
BUCKET_NOT_FOUND)) {
+        throw new OMException(
+            "Cannot follow bucket link: linked source bucket does not exist",
+            BUCKET_NOT_FOUND);

Review Comment:
   Now that the hardcoded result code has been replaced with `e.getResult()`, 
the unit and robot tests are failing due to mismatched expectations.
   Update the tests to assert the correct result code.



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