zentol commented on a change in pull request #13547:
URL: https://github.com/apache/flink/pull/13547#discussion_r508373270
##########
File path:
flink-runtime/src/main/java/org/apache/flink/runtime/metrics/util/MetricUtils.java
##########
@@ -132,6 +136,17 @@ public static void instantiateStatusMetrics(
instantiateCPUMetrics(jvm.addGroup("CPU"));
}
+ public static void instantiateManagedMemoryMetrics(
+ MetricGroup metricGroup,
+ TaskExecutor taskExecutor) {
+ checkNotNull(metricGroup);
+ checkNotNull(taskExecutor);
+
+ MetricGroup managedMemoryMetricGroup =
metricGroup.addGroup(METRIC_GROUP_MANAGED_MEMORY);
+ managedMemoryMetricGroup.gauge(MetricNames.MEMORY_USED,
taskExecutor::getUsedManagedMemory);
+ managedMemoryMetricGroup.gauge(MetricNames.MEMORY_MAX,
taskExecutor::getTotalManagedMemory);
Review comment:
We use max for various other memory-related metrics, describing the
maximum amount that _could_ be used. I think we'd create more confusion by
introducing new terminology.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]