Nitin-Kashyap commented on code in PR #27784:
URL: https://github.com/apache/doris/pull/27784#discussion_r1414249380
##########
fe/fe-core/src/main/java/org/apache/doris/catalog/external/HMSExternalTable.java:
##########
@@ -438,9 +469,85 @@ public List<Column> initSchema() {
columns = tmpSchema;
}
initPartitionColumns(columns);
+ initBucketingColumns(columns);
return columns;
}
+ private void initBucketingColumns(List<Column> columns) {
+ List<String> bucketCols = new ArrayList<>(5);
+ int numBuckets = getBucketColums(bucketCols);
+ if (bucketCols.isEmpty()) {
+ bucketColumns = ImmutableList.of();
+ distributionInfo = new RandomDistributionInfo(1, true);
+ return;
+ }
+
+ int bucketingVersion =
Integer.valueOf(remoteTable.getParameters().getOrDefault(BUCKETING_VERSION,
+ "2"));
+ ImmutableList.Builder<Column> bucketColBuilder =
ImmutableList.builder();
+ for (String colName : bucketCols) {
+ // do not use "getColum()", which will cause dead loop
Review Comment:
fixed
--
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]