jadami10 commented on code in PR #12464:
URL: https://github.com/apache/pinot/pull/12464#discussion_r1501147536
##########
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/utils/TableConfigUtils.java:
##########
@@ -490,6 +493,19 @@ public static void validateIngestionConfig(TableConfig
tableConfig, @Nullable Sc
Preconditions.checkState(new
HashSet<>(schema.getMetricNames()).equals(aggregationColumns),
"all metric columns must be aggregated");
}
+
+ // This is required by
MutableSegmentImpl.enableMetricsAggregationIfPossible().
+ // That code will disable ingestion aggregation if all metrics aren't
noDictionaryColumns.
+ // But if you do that after the table is already created, all future
aggregations will
+ // just be the default value.
+ Map<String, FieldIndexConfigs> fieldIndexConfigsMap =
FieldIndexConfigsUtil.createIndexConfigsByColName(
Review Comment:
great suggestion, thank you. I think is should be `.isDisabled()`. Or at
least that's what tests say.
There's honestly a lot of places we might want to clean this up. The
invertedIndex check is based solely on the `noDictionaryColumn` config for
example. I'm surprised more people aren't running into this.
--
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]