abhioncbr commented on code in PR #10656:
URL: https://github.com/apache/pinot/pull/10656#discussion_r1204607591


##########
pinot-common/src/main/java/org/apache/pinot/common/utils/config/TableConfigUtils.java:
##########
@@ -444,4 +447,36 @@ public static boolean 
hasPreConfiguredInstancePartitions(TableConfig tableConfig
     return hasPreConfiguredInstancePartitions(tableConfig)
         && 
tableConfig.getInstancePartitionsMap().containsKey(instancePartitionsType);
   }
+
+  /**
+   * Get the partition column from InstanceAssignmentConfigUtils
+   * @param tableConfig table config
+   * @return partition column
+   */
+  public static String getPartitionColumn(TableConfig tableConfig) {
+    String partitionColumn = null;
+
+    // check getInstanceAssignmentConfigMap is null or empty,
+    if (!MapUtils.isEmpty(tableConfig.getInstanceAssignmentConfigMap())) {
+      for (String key : tableConfig.getInstanceAssignmentConfigMap().keySet()) 
{
+        //check getInstanceAssignmentConfigMap has the key of TableType
+        if (Objects.equals(key, tableConfig.getTableType().toString())) {

Review Comment:
   It is updated as per the comments. Please have another look. Thanks



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