snleee commented on code in PR #10387:
URL: https://github.com/apache/pinot/pull/10387#discussion_r1133266216


##########
pinot-plugins/pinot-minion-tasks/pinot-minion-builtin-tasks/src/main/java/org/apache/pinot/plugin/minion/tasks/mergerollup/MergeRollupTaskGenerator.java:
##########
@@ -275,12 +289,21 @@ public List<PinotTaskConfig> 
generateTasks(List<TableConfig> tableConfigs) {
           }
           _tableLowestLevelMaxValidBucketEndTimeMs.put(tableNameWithType, 
lowestLevelMaxValidBucketEndTimeMs);
         }
-        // Create delay metrics even if there's no task scheduled, this helps 
the case that the controller is restarted
+        // Create metrics even if there's no task scheduled, this helps the 
case that the controller is restarted
         // but the metrics are not available until the controller schedules a 
valid task
-        createOrUpdateDelayMetrics(tableNameWithType, mergeLevel, null, 
watermarkMs, bufferMs, bucketMs);
-        if (!isValidBucketEndTime(bucketEndMs, bufferMs, lowerMergeLevel, 
mergeRollupTaskMetadata)) {
-          LOGGER.info("Bucket with start: {} and end: {} (table : {}, 
mergeLevel : {}) cannot be merged yet",
-              bucketStartMs, bucketEndMs, tableNameWithType, mergeLevel);
+        List<String> sortedMergeLevels =
+            sortedMergeLevelConfigs.stream().map(e -> 
e.getKey()).collect(Collectors.toList());
+        if (processAll) {

Review Comment:
   Why don't we emit both metrics in both cases? 
   
   1. numBuckets to process is anyway going to be useful for original mode.
   2. watermark may not mean much for `processAll` mode but we still can alert 
if there's no tasks get scheduled for new time buckets for a long time. This 
allows us to be able to alert on "no activity for a long time" on a single 
metric.



-- 
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-unsubscr...@pinot.apache.org

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


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

Reply via email to