morningman commented on a change in pull request #5733: URL: https://github.com/apache/incubator-doris/pull/5733#discussion_r623184517
########## File path: fe/fe-core/src/main/java/org/apache/doris/catalog/Partition.java ########## @@ -500,4 +508,17 @@ public boolean convertRandomDistributionToHashDistribution(List<Column> baseSche } return hasChanged; } + + private static void registerMetric(Partition partition) { + GaugeMetric<Long> gauge = new GaugeMetric<Long>("partition_query_count", + Metric.MetricUnit.NOUNIT, "partition query count") { + @Override + public Long getValue() { + return partition.partition_query_count.longValue(); + } + }; + gauge.addLabel(new MetricLabel("partition_name", partition.getName())); + gauge.addLabel(new MetricLabel("partition_id", String.valueOf(partition.getId()))); + MetricRepo.addMetric(gauge); Review comment: Are you sure to add gauge for each partition? There will be a huge number of metrics... -- 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: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org