J-HowHuang opened a new pull request, #15575: URL: https://github.com/apache/pinot/pull/15575
## Description Replica groups is an important config that user often check while operating table rebalance. To avoid any overlook, this PR escalates the check into one of the pre-check items. This check goes to `TableConfig` to get the information of 1. numReplicaGroups 2. numInstancesPerReplicaGroup for each instance partition type (`OFFLINE`, `COMPLETED`, `CONSUMING`) Because this checks only the table config instead of the actual instance assignment resulting from the rebalance, the replica group information from the table config might not align with the actual fact after the rebalance when `reassignInstance=false` . We give a warning in this case, otherwise this pre-check passes with the above info in the message. ## Examples ### Replica groups enabled <img width="600" alt="image" src="https://github.com/user-attachments/assets/3cbe8c90-5964-4bf3-a393-ca9cb613d624" /> Rebalance result: ``` "instanceAssignment": { "CONSUMING": { "instancePartitionsName": "airlineStats_CONSUMING", "partitionToInstancesMap": { "0_0": [ "Server_<redacted>_7051" ] } }, "COMPLETED": { "instancePartitionsName": "airlineStats_COMPLETED", "partitionToInstancesMap": { "0_0": [ "Server_<redacted>_7051" ], "0_1": [ "Server_<redacted>_7050" ] } } } ``` ### Replica groups disabled <img width="611" alt="image" src="https://github.com/user-attachments/assets/497ed2c3-f400-469d-9b03-40f77860c201" /> Rebalance result: ``` { "CONSUMING": { "instancePartitionsName": "airlineStats_CONSUMING", "partitionToInstancesMap": { "0_0": [ "Server_<redacted>_7051", "Server_<redacted>_7050" ] } }, "COMPLETED": { "instancePartitionsName": "airlineStats_COMPLETED", "partitionToInstancesMap": { "0_0": [ "Server_<redacted>_7051" ], "0_1": [ "Server_<redacted>_7050" ] } } } ``` ### Rebalance with `reassignInstances=false` <img width="613" alt="image" src="https://github.com/user-attachments/assets/a36b1d64-c59c-463d-966c-e669fa467de2" /> Rebalance result (notice that the actual instance assignment is not updated): ``` { "CONSUMING": { "instancePartitionsName": "airlineStats_CONSUMING", "partitionToInstancesMap": { "0_0": [ "Server_<redacted>_7051", "Server_<redacted>_7050" ] } }, "COMPLETED": { "instancePartitionsName": "airlineStats_COMPLETED", "partitionToInstancesMap": { "0_0": [ "Server_<redacted>_7051", "Server_<redacted>_7050" ] } } } ``` ### Rebalance with OFFLINE tables, with `numInstancesPerReplicaGroup=0` <img width="698" alt="image" src="https://github.com/user-attachments/assets/2ca6d428-daea-4fed-ae6e-fce9820209db" /> Rebalance result: ``` { "OFFLINE": { "instancePartitionsName": "airlineStats_OFFLINE", "partitionToInstancesMap": { "0_0": [ "Server_100.114.242.49_7051", "Server_100.114.242.49_7053", "Server_100.114.242.49_7055" ], "0_1": [ "Server_100.114.242.49_7052", "Server_100.114.242.49_7054", "Server_100.114.242.49_7050" ] } } } ``` -- 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