You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by GitBox <gi...@apache.org> on 2022/04/18 20:16:45 UTC
[GitHub] [ozone] kerneltime commented on a diff in pull request #3302: HDDS-6529. Adding Unit-Test cases for S3-Gateway Object-Endpoint Metrics
kerneltime commented on code in PR #3302:
URL: https://github.com/apache/ozone/pull/3302#discussion_r852383603
##########
hadoop-ozone/s3gateway/src/main/java/org/apache/hadoop/ozone/s3/endpoint/ObjectEndpoint.java:
##########
@@ -230,6 +230,14 @@ public Response put(
}
LOG.error("Exception occurred in PutObject", ex);
throw ex;
+ } catch (OS3Exception ex) {
+ if (copyHeader != null) {
+ getMetrics().incCopyObjectFailure();
+ } else {
+ getMetrics().incCreateKeyFailure();
+ }
+ LOG.error("Exception occurred in PutObject", ex.getMessage());
Review Comment:
I don't think it is a good idea to log errors that can be triggered by user error. This should go into a dedicated access log https://issues.apache.org/jira/browse/HDDS-6559
--
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: issues-unsubscribe@ozone.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org