kerneltime commented on code in PR #3594:
URL: https://github.com/apache/ozone/pull/3594#discussion_r925064081
##########
hadoop-ozone/s3gateway/src/main/java/org/apache/hadoop/ozone/s3/endpoint/ObjectEndpoint.java:
##########
@@ -230,6 +233,9 @@ public Response put(
throw os3Exception;
} else if (ex.getResult() == ResultCodes.PERMISSION_DENIED) {
throw newError(S3ErrorTable.ACCESS_DENIED, keyPath, ex);
+ } else if (ex.getResult() == ResultCodes.BUCKET_NOT_FOUND
+ || ex.getResult() == ResultCodes.VOLUME_NOT_FOUND) {
+ throw newError(S3ErrorTable.NO_SUCH_BUCKET, bucketName, ex);
Review Comment:
Thanks @smengcl for the review. Volume not found should actually be treated
differently than bucket not found. Volume not found would indicate a
misconfigured system and should show up in both audit and s3g log. Bucket not
found should only be in audit log as this is most likely a misconfigured 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]