DomGarguilo commented on code in PR #5894:
URL: https://github.com/apache/accumulo/pull/5894#discussion_r2433603869
##########
server/monitor/src/main/java/org/apache/accumulo/monitor/next/Endpoints.java:
##########
@@ -151,6 +151,18 @@ public MetricResponse getManager() {
return monitor.getInformationFetcher().getAllMetrics().asMap().get(s);
}
+ @GET
+ @Path("manager/metrics")
+ @Produces(MediaType.APPLICATION_JSON)
+ @Description("Returns the metrics for the Manager")
+ public List<FMetric> getManagerMetrics() {
+ if (getManager().getMetrics() != null) {
+ return getManager().getMetrics().stream().map(FMetric::getRootAsFMetric)
+ .collect(Collectors.toList());
Review Comment:
```suggestion
List<ByteBuffer> metrics = getManager().getMetrics();
if (metrics != null) {
return
metrics.stream().map(FMetric::getRootAsFMetric).collect(Collectors.toList());
```
--
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]