maytasm commented on a change in pull request #10026:
URL: https://github.com/apache/druid/pull/10026#discussion_r441223545
##########
File path:
processing/src/main/java/org/apache/druid/query/aggregation/LongSumAggregatorFactory.java
##########
@@ -87,8 +89,12 @@ protected VectorAggregator factorizeVector(
}
@Override
- public boolean canVectorize()
+ public boolean canVectorize(ColumnCapabilitiesProvider
columnCapabilitiesProvider)
{
+ if (fieldName != null) {
+ final ColumnCapabilities originalCapabilities =
columnCapabilitiesProvider.getColumnCapabilities(fieldName);
+ return expression == null && (originalCapabilities == null ||
originalCapabilities.getType().isNumeric());
+ }
Review comment:
SchemaEvolutionTest and DoubleMeanAggregationTest with Vectorize.TRUE
triggers the bug case (where the column is not numeric and cannot be
vectorized). I have made these tests run in both Vectorize.TRUE and
Vectorize.FALSE mode to verify this fix. There are some other existing tests
that are happy path (where the column is numeric and can be vectorized)
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]