nizarhejazi commented on code in PR #8927: URL: https://github.com/apache/pinot/pull/8927#discussion_r906996320
########## pinot-core/src/main/java/org/apache/pinot/core/operator/blocks/IntermediateResultsBlock.java: ########## @@ -80,45 +83,69 @@ public IntermediateResultsBlock() { /** * Constructor for selection result. */ - public IntermediateResultsBlock(DataSchema dataSchema, Collection<Object[]> selectionResult) { + public IntermediateResultsBlock(DataSchema dataSchema, Collection<Object[]> selectionResult, + boolean isNullHandlingEnabled) { _dataSchema = dataSchema; _selectionResult = selectionResult; + _isNullHandlingEnabled = isNullHandlingEnabled; } /** * Constructor for aggregation result. * <p>For aggregation only, the result is a list of values. * <p>For aggregation group-by, the result is a list of maps from group keys to aggregation values. */ - public IntermediateResultsBlock(AggregationFunction[] aggregationFunctions, List<Object> aggregationResult) { + public IntermediateResultsBlock(AggregationFunction[] aggregationFunctions, List<Object> aggregationResult, + boolean isNullHandlingEnabled) { _aggregationFunctions = aggregationFunctions; _aggregationResult = aggregationResult; + _isNullHandlingEnabled = isNullHandlingEnabled; + } + + /** + * Constructor for aggregation result. + * <p>For aggregation only, the result is a list of values. + * <p>For aggregation group-by, the result is a list of maps from group keys to aggregation values. + */ + public IntermediateResultsBlock(AggregationFunction[] aggregationFunctions, List<Object> aggregationResult, + DataSchema dataSchema, boolean isNullHandlingEnabled) { + _aggregationFunctions = aggregationFunctions; + _aggregationResult = aggregationResult; + _dataSchema = dataSchema; + _isNullHandlingEnabled = isNullHandlingEnabled; } /** * Constructor for aggregation group-by order-by result with {@link AggregationGroupByResult}. */ public IntermediateResultsBlock(AggregationFunction[] aggregationFunctions, - @Nullable AggregationGroupByResult aggregationGroupByResults, DataSchema dataSchema) { + @Nullable AggregationGroupByResult aggregationGroupByResults, DataSchema dataSchema, + boolean isNullHandlingEnabled) { _aggregationFunctions = aggregationFunctions; _aggregationGroupByResult = aggregationGroupByResults; _dataSchema = dataSchema; + _isNullHandlingEnabled = isNullHandlingEnabled; } /** * Constructor for aggregation group-by order-by result with {@link AggregationGroupByResult} and * with a collection of intermediate records. */ public IntermediateResultsBlock(AggregationFunction[] aggregationFunctions, - Collection<IntermediateRecord> intermediateRecords, DataSchema dataSchema) { + Collection<IntermediateRecord> intermediateRecords, DataSchema dataSchema, boolean isNullHandlingEnabled) { _aggregationFunctions = aggregationFunctions; _dataSchema = dataSchema; _intermediateRecords = intermediateRecords; + _isNullHandlingEnabled = isNullHandlingEnabled; } public IntermediateResultsBlock(Table table) { _table = table; - _dataSchema = table.getDataSchema(); + if (_table != null) { Review Comment: Not needed anymore. ########## pinot-core/src/main/java/org/apache/pinot/core/operator/combine/GroupByOrderByCombineOperator.java: ########## @@ -235,11 +235,15 @@ protected IntermediateResultsBlock mergeResults() } IndexedTable indexedTable = _indexedTable; - indexedTable.finish(false); + if (indexedTable != null) { Review Comment: Not needed anymore. -- 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