LakshSingla commented on code in PR #14462:
URL: https://github.com/apache/druid/pull/14462#discussion_r1282709307
##########
processing/src/main/java/org/apache/druid/query/aggregation/first/DoubleFirstAggregator.java:
##########
@@ -19,30 +19,36 @@
package org.apache.druid.query.aggregation.first;
-import org.apache.druid.collections.SerializablePair;
-import org.apache.druid.segment.BaseDoubleColumnValueSelector;
+import org.apache.druid.query.aggregation.SerializablePairLongDouble;
import org.apache.druid.segment.BaseLongColumnValueSelector;
+import org.apache.druid.segment.ColumnValueSelector;
-public class DoubleFirstAggregator extends
NumericFirstAggregator<BaseDoubleColumnValueSelector>
+public class DoubleFirstAggregator extends NumericFirstAggregator
{
double firstValue;
- public DoubleFirstAggregator(BaseLongColumnValueSelector timeSelector,
BaseDoubleColumnValueSelector valueSelector)
+ public DoubleFirstAggregator(BaseLongColumnValueSelector timeSelector,
ColumnValueSelector valueSelector, boolean needsFoldCheck)
Review Comment:
@somu-imply I am not completely aware of the foldCheck, which
implementation of the selectors produces results that cannot be optimized?
Also, is there any particular reason that double won't require the check, since
it seems analogous to what StringFirst et al. are doing?
--
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]