Skip to content

Commit 1723a94

Browse files
Adding request error tags for percentile timer (#661)
1 parent c942098 commit 1723a94

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

metacat-main/src/main/java/com/netflix/metacat/main/api/RequestWrapper.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -269,15 +269,18 @@ public <R> R processRequest(
269269
return supplier.get();
270270
} catch (UnsupportedOperationException e) {
271271
collectRequestExceptionMetrics(tags, e.getClass().getSimpleName());
272+
percentileTags.put("request_error", "true");
272273
log.error(e.getMessage(), e);
273274
throw new MetacatNotSupportedException("Catalog does not support the operation. " + e.getMessage());
274275
} catch (IllegalArgumentException e) {
275276
collectRequestExceptionMetrics(tags, e.getClass().getSimpleName());
277+
percentileTags.put("request_error", "true");
276278
log.error(e.getMessage(), e);
277279
throw new MetacatBadRequestException(String.format("%s.%s", e.getMessage(),
278280
e.getCause() == null ? "" : e.getCause().getMessage()));
279281
} catch (Exception e) {
280282
collectRequestExceptionMetrics(tags, e.getClass().getSimpleName());
283+
percentileTags.put("request_error", "true");
281284
final String message = String
282285
.format("%s.%s -- %s failed.",
283286
e.getMessage(), e.getCause() == null ? "" : e.getCause().getMessage(),

0 commit comments

Comments
 (0)