use of org.apache.hyracks.dataflow.std.sort.HybridTopKSortRunGenerator in project asterixdb by apache.
the class TopKRunGeneratorTest method testHybridTopKShouldSwitchToFrameSorterWhenFlushed.
@Test
public void testHybridTopKShouldSwitchToFrameSorterWhenFlushed() {
int topK = 1;
IHyracksTaskContext ctx = AbstractRunGeneratorTest.testUtils.create(PAGE_SIZE);
AbstractSortRunGenerator sorter = new HybridTopKSortRunGenerator(ctx, SORT_FRAME_LIMIT, topK, SortFields, null, ComparatorFactories, RecordDesc);
}
use of org.apache.hyracks.dataflow.std.sort.HybridTopKSortRunGenerator in project asterixdb by apache.
the class TopKRunGeneratorTest method testHybridTopKShouldNotGenerateAnyRuns.
@Test
public void testHybridTopKShouldNotGenerateAnyRuns() throws HyracksDataException {
int topK = 1;
IHyracksTaskContext ctx = AbstractRunGeneratorTest.testUtils.create(PAGE_SIZE);
AbstractSortRunGenerator sorter = new HybridTopKSortRunGenerator(ctx, SORT_FRAME_LIMIT, topK, SortFields, null, ComparatorFactories, RecordDesc);
testInMemoryOnly(ctx, topK, ORDER.REVERSE, sorter);
}
Aggregations