public class InMemoryHashAggregationBuilder extends Object implements HashAggregationBuilder
| Constructor and Description |
|---|
InMemoryHashAggregationBuilder(List<AccumulatorFactory> accumulatorFactories,
AggregationNode.Step step,
int expectedGroups,
List<Type> groupByTypes,
List<Integer> groupByChannels,
Optional<Integer> hashChannel,
OperatorContext operatorContext,
Optional<io.airlift.units.DataSize> maxPartialMemory,
JoinCompiler joinCompiler,
UpdateMemory updateMemory) |
InMemoryHashAggregationBuilder(List<AccumulatorFactory> accumulatorFactories,
AggregationNode.Step step,
int expectedGroups,
List<Type> groupByTypes,
List<Integer> groupByChannels,
Optional<Integer> hashChannel,
OperatorContext operatorContext,
Optional<io.airlift.units.DataSize> maxPartialMemory,
Optional<Integer> overwriteIntermediateChannelOffset,
JoinCompiler joinCompiler,
UpdateMemory updateMemory) |
| Modifier and Type | Method and Description |
|---|---|
WorkProcessor<Page> |
buildHashSortedResult() |
List<Type> |
buildIntermediateTypes() |
WorkProcessor<Page> |
buildResult() |
List<Type> |
buildTypes() |
void |
close() |
void |
finishMemoryRevoke() |
int |
getCapacity() |
double |
getExpectedHashCollisions() |
long |
getGroupCount() |
long |
getGroupIdsSortingSize()
building hash sorted results requires memory for sorting group IDs.
|
long |
getHashCollisions() |
int |
getKeyChannels() |
long |
getSizeInMemory() |
boolean |
isFull() |
Work<?> |
processPage(Page page) |
void |
recordHashCollisions(HashCollisionsCounter hashCollisionsCounter) |
void |
setOutputPartial() |
com.google.common.util.concurrent.ListenableFuture<?> |
startMemoryRevoke() |
static List<Type> |
toTypes(List<? extends Type> groupByType,
AggregationNode.Step step,
List<AccumulatorFactory> factories,
Optional<Integer> hashChannel) |
void |
updateMemory() |
public InMemoryHashAggregationBuilder(List<AccumulatorFactory> accumulatorFactories, AggregationNode.Step step, int expectedGroups, List<Type> groupByTypes, List<Integer> groupByChannels, Optional<Integer> hashChannel, OperatorContext operatorContext, Optional<io.airlift.units.DataSize> maxPartialMemory, JoinCompiler joinCompiler, UpdateMemory updateMemory)
public InMemoryHashAggregationBuilder(List<AccumulatorFactory> accumulatorFactories, AggregationNode.Step step, int expectedGroups, List<Type> groupByTypes, List<Integer> groupByChannels, Optional<Integer> hashChannel, OperatorContext operatorContext, Optional<io.airlift.units.DataSize> maxPartialMemory, Optional<Integer> overwriteIntermediateChannelOffset, JoinCompiler joinCompiler, UpdateMemory updateMemory)
public void close()
close in interface HashAggregationBuilderclose in interface AutoCloseablepublic Work<?> processPage(Page page)
processPage in interface HashAggregationBuilderpublic void updateMemory()
updateMemory in interface HashAggregationBuilderpublic boolean isFull()
isFull in interface HashAggregationBuilderpublic void recordHashCollisions(HashCollisionsCounter hashCollisionsCounter)
recordHashCollisions in interface HashAggregationBuilderpublic long getHashCollisions()
public double getExpectedHashCollisions()
public com.google.common.util.concurrent.ListenableFuture<?> startMemoryRevoke()
startMemoryRevoke in interface HashAggregationBuilderpublic void finishMemoryRevoke()
finishMemoryRevoke in interface HashAggregationBuilderpublic long getSizeInMemory()
public long getGroupIdsSortingSize()
public void setOutputPartial()
public int getKeyChannels()
public long getGroupCount()
public WorkProcessor<Page> buildResult()
buildResult in interface HashAggregationBuilderpublic WorkProcessor<Page> buildHashSortedResult()
public int getCapacity()
public static List<Type> toTypes(List<? extends Type> groupByType, AggregationNode.Step step, List<AccumulatorFactory> factories, Optional<Integer> hashChannel)
Copyright © 2012–2019. All rights reserved.