use of io.crate.data.join.CrossJoinNLBatchIterator in project crate by crate.
the class NestedLoopOperation method buildCrossJoinBatchIterator.
private static BatchIterator<Row> buildCrossJoinBatchIterator(BatchIterator<Row> left, BatchIterator<Row> right, CombinedRow combiner, CircuitBreaker circuitBreaker, RamAccounting ramAccounting, List<DataType<?>> leftSideColumnTypes, long estimatedRowsSizeLeft, long estimatedNumberOfRowsLeft, boolean blockNestedLoop) {
if (blockNestedLoop) {
IntSupplier blockSizeCalculator = new RamBlockSizeCalculator(Paging.PAGE_SIZE, circuitBreaker, estimatedRowsSizeLeft, estimatedNumberOfRowsLeft);
var rowAccounting = new RowCellsAccountingWithEstimators(leftSideColumnTypes, ramAccounting, 0);
return new CrossJoinBlockNLBatchIterator(left, right, combiner, blockSizeCalculator, rowAccounting);
} else {
return new CrossJoinNLBatchIterator<>(left, right, combiner);
}
}
Aggregations