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 2022/09/07 17:19:00 UTC
[GitHub] [pinot] jackjlli commented on a diff in pull request #9339: delete all related minion task metadata when deleting a table
jackjlli commented on code in PR #9339:
URL: https://github.com/apache/pinot/pull/9339#discussion_r965099462
##########
pinot-controller/src/main/java/org/apache/pinot/controller/helix/core/PinotHelixResourceManager.java:
##########
@@ -1930,6 +1938,14 @@ public void deleteRealtimeTable(String tableName, @Nullable String retentionPeri
realtimeTableName);
LOGGER.info("Deleting table {}: Removed merge realtime to offline metadata", realtimeTableName);
+ // Remove all task metadata
+ // TODO: This only deletes the new ZNode MINION_TASK_METADATA/${offlineTableName} but not the old one
+ // MINION_TASK_METADATA/<task type>/${offlineTableName}, so we keep the above logic of deleting task
+ // metadata for specific task types. The above logic should be deleted once the old ZNode is not in
+ // use any more.
+ MinionTaskMetadataUtils.deleteTaskMetadata(_propertyStore, realtimeTableName);
+ LOGGER.info("Deleting all task metadata for table {}", realtimeTableName);
Review Comment:
Same here.
##########
pinot-controller/src/main/java/org/apache/pinot/controller/helix/core/PinotHelixResourceManager.java:
##########
@@ -1863,6 +1863,14 @@ public void deleteOfflineTable(String tableName, @Nullable String retentionPerio
offlineTableName);
LOGGER.info("Deleting table {}: Removed merge rollup task metadata", offlineTableName);
+ // Remove all task metadata
+ // TODO: This only deletes the new ZNode MINION_TASK_METADATA/${offlineTableName} but not the old one
+ // MINION_TASK_METADATA/<task type>/${offlineTableName}, so we keep the above logic of deleting task
+ // metadata for specific task types. The above logic should be deleted once the old ZNode is not in
+ // use any more.
+ MinionTaskMetadataUtils.deleteTaskMetadata(_propertyStore, offlineTableName);
+ LOGGER.info("Deleting all task metadata for table {}", offlineTableName);
Review Comment:
nit: it'd be good to follow the message pattern, check the ones in Line 1859, Line 1864, etc.
--
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