Search in sources :

Example 1 with PartitionSenderRootExec

use of org.apache.drill.exec.physical.impl.partitionsender.PartitionSenderRootExec in project drill by apache.

the class OrderedPartitionSenderCreator method getRoot.

@SuppressWarnings("resource")
@Override
public RootExec getRoot(FragmentContext context, OrderedPartitionSender config, List<RecordBatch> children) throws ExecutionSetupException {
    Preconditions.checkArgument(children.size() == 1);
    List<RecordBatch> ordered_children = Lists.newArrayList();
    ordered_children.add(new OrderedPartitionRecordBatch(config, children.iterator().next(), context));
    HashPartitionSender hpc = new HashPartitionSender(config.getOppositeMajorFragmentId(), config, config.getRef(), config.getDestinations());
    return new PartitionSenderRootExec(context, ordered_children.iterator().next(), hpc);
}
Also used : HashPartitionSender(org.apache.drill.exec.physical.config.HashPartitionSender) PartitionSenderRootExec(org.apache.drill.exec.physical.impl.partitionsender.PartitionSenderRootExec) RecordBatch(org.apache.drill.exec.record.RecordBatch)

Aggregations

HashPartitionSender (org.apache.drill.exec.physical.config.HashPartitionSender)1 PartitionSenderRootExec (org.apache.drill.exec.physical.impl.partitionsender.PartitionSenderRootExec)1 RecordBatch (org.apache.drill.exec.record.RecordBatch)1