somandal commented on code in PR #15029:
URL: https://github.com/apache/pinot/pull/15029#discussion_r1953368390
##########
pinot-controller/src/main/java/org/apache/pinot/controller/helix/core/rebalance/TableRebalancer.java:
##########
@@ -186,13 +190,21 @@ private RebalanceResult doRebalance(TableConfig
tableConfig, RebalanceConfig reb
&&
RoutingConfig.STRICT_REPLICA_GROUP_INSTANCE_SELECTOR_TYPE.equalsIgnoreCase(
tableConfig.getRoutingConfig().getInstanceSelectorType());
LOGGER.info(
- "Start rebalancing table: {} with dryRun: {}, reassignInstances: {},
includeConsuming: {}, bootstrap: {}, "
- + "downtime: {}, minReplicasToKeepUpForNoDowntime: {},
enableStrictReplicaGroup: {}, lowDiskMode: {}, "
- + "bestEfforts: {}, externalViewCheckIntervalInMs: {},
externalViewStabilizationTimeoutInMs: {}",
- tableNameWithType, dryRun, reassignInstances, includeConsuming,
bootstrap, downtime,
+ "Start rebalancing table: {} with dryRun: {}, preChecks: {},
reassignInstances: {}, includeConsuming: {}, "
+ + "bootstrap: {}, downtime: {}, minReplicasToKeepUpForNoDowntime:
{}, enableStrictReplicaGroup: {}, "
+ + "lowDiskMode: {}, bestEfforts: {},
externalViewCheckIntervalInMs: {}, "
+ + "externalViewStabilizationTimeoutInMs: {}",
+ tableNameWithType, dryRun, preChecks, reassignInstances,
includeConsuming, bootstrap, downtime,
minReplicasToKeepUpForNoDowntime, enableStrictReplicaGroup,
lowDiskMode, bestEfforts,
externalViewCheckIntervalInMs, externalViewStabilizationTimeoutInMs);
+ // Perform pre-checks if enabled
+ Map<String, String> preChecksResult = null;
+ if (preChecks && _pinotHelixResourceManager != null) {
+ preChecksResult =
_pinotHelixResourceManager.getRebalancePreChecker().doRebalancePreChecks(rebalanceJobId,
+ tableNameWithType, tableConfig, _pinotHelixResourceManager);
Review Comment:
I was actually letting all the checks happen, and letting dry run get
populated and then checking and returning after that. My thought was that we
could still populate the status of dry-run / pre-checks.
I've moved the check here as suggested though, I guess it is fine to just
force the user to pass the right flags depending on intent.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]