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



##########
File path: 
pinot-controller/src/main/java/org/apache/pinot/controller/helix/core/retention/RetentionManager.java
##########
@@ -258,10 +258,11 @@ private void 
manageSegmentLineageCleanupForTable(TableConfig tableConfig) {
         if (SegmentLineageAccessHelper
             
.writeSegmentLineage(_pinotHelixResourceManager.getPropertyStore(), 
segmentLineage, expectedVersion)) {
           // Delete segments based on the segment lineage
-          _pinotHelixResourceManager.deleteSegments(tableNameWithType, 
segmentsToDelete);
-          LOGGER.info("Finished cleaning up segment lineage for table: {}, 
deleted segments: {} in {}ms",
-              tableNameWithType, StringUtils.join(segmentsToDelete, ","),
-              (System.currentTimeMillis() - cleanupStartTime));
+          if (!segmentsToDelete.isEmpty()) {

Review comment:
       not really. We will have the following log anyway in case we 
successfully processed the table. If nothing is deleted, we don't need to add 
the log. (no log means no deletion happened)
   ```
       LOGGER.info("Segment lineage metadata clean-up is successfully processed 
for table: {}", tableNameWithType);
   ```




-- 
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