Module org.elasticsearch.compute
Interface AggregatorFunction
- All Superinterfaces:
AutoCloseable,Closeable,org.elasticsearch.core.Releasable
- All Known Implementing Classes:
CountAggregatorFunction,FromPartialAggregatorFunction,ToPartialAggregatorFunction
public interface AggregatorFunction
extends org.elasticsearch.core.Releasable
A non-grouped aggregation.
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddIntermediateInput(Page page) Add a pre-aggregated page worth of "intermediate" input.voidaddRawInput(Page page, BooleanVector mask) Add a page worth of data to the aggregation.voidevaluateFinal(Block[] blocks, int offset, DriverContext driverContext) Build the final results from running this agg.voidevaluateIntermediate(Block[] blocks, int offset, DriverContext driverContext) Build pre-aggregated "intermediate" data to pass to theaddIntermediateInput(org.elasticsearch.compute.data.Page).intThe number of blocks used by intermediate state.Methods inherited from interface org.elasticsearch.core.Releasable
close
-
Method Details
-
addRawInput
Add a page worth of data to the aggregation.- Parameters:
mask- a mask to apply to the positions. If the position isfalsethen the aggregation should skip it.
-
addIntermediateInput
Add a pre-aggregated page worth of "intermediate" input. This intermediate input will have been created by callingevaluateIntermediate(org.elasticsearch.compute.data.Block[], int, org.elasticsearch.compute.operator.DriverContext)on this agg, though likely in a differentDriverand maybe on a different physical node. -
evaluateIntermediate
Build pre-aggregated "intermediate" data to pass to theaddIntermediateInput(org.elasticsearch.compute.data.Page).- Parameters:
blocks- write the output into this arrayoffset- write the firstBlockat this offset inblocks
-
evaluateFinal
Build the final results from running this agg.- Parameters:
blocks- write the output into this arrayoffset- write the firstBlockat this offset inblocks
-
intermediateBlockCount
int intermediateBlockCount()The number of blocks used by intermediate state.
-