You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by GitBox <gi...@apache.org> on 2021/11/06 00:46:14 UTC

[GitHub] [pinot] snleee commented on a change in pull request #7557: Clean up controller-table related metrics in ControllerPeriodicTask

snleee commented on a change in pull request #7557:
URL: https://github.com/apache/pinot/pull/7557#discussion_r744037264



##########
File path: pinot-controller/src/main/java/org/apache/pinot/controller/validation/OfflineSegmentIntervalChecker.java
##########
@@ -136,6 +136,20 @@ private void validateOfflineSegmentPush(TableConfig tableConfig) {
     _validationMetrics.updateSegmentCountGauge(offlineTableName, numSegments);
   }
 
+  @Override
+  protected void nonLeaderCleanup(List<String> tableNamesWithType) {
+    for (String tableNameWithType : tableNamesWithType) {
+      TableType tableType = TableNameBuilder.getTableTypeFromTableName(tableNameWithType);
+      if (tableType == TableType.OFFLINE) {
+        _validationMetrics.cleanupMissingSegmentCountGauge(tableNameWithType);

Review comment:
       Can you add at least `TODO` comment to clean this up? We can simply loop through all the enum values from `ValidationMetricName` and clean up the 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.

To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org