[pipelineX](improvement) Support local shuffle for join and agg (#27852)
This commit is contained in:
@ -310,6 +310,7 @@ public class PhysicalPlanTranslator extends DefaultPlanVisitor<PlanFragment, Pla
|
||||
}
|
||||
}
|
||||
DataPartition dataPartition = toDataPartition(distribute.getDistributionSpec(), validOutputIds, context);
|
||||
exchangeNode.setPartitionType(dataPartition.getType());
|
||||
PlanFragment parentFragment = new PlanFragment(context.nextFragmentId(), exchangeNode, dataPartition);
|
||||
exchangeNode.setNumInstances(inputFragment.getPlanRoot().getNumInstances());
|
||||
if (distribute.getDistributionSpec() instanceof DistributionSpecGather) {
|
||||
|
||||
@ -29,6 +29,7 @@ import org.apache.doris.statistics.StatisticalType;
|
||||
import org.apache.doris.statistics.StatsRecursiveDerive;
|
||||
import org.apache.doris.thrift.TExchangeNode;
|
||||
import org.apache.doris.thrift.TExplainLevel;
|
||||
import org.apache.doris.thrift.TPartitionType;
|
||||
import org.apache.doris.thrift.TPlanNode;
|
||||
import org.apache.doris.thrift.TPlanNodeType;
|
||||
|
||||
@ -64,6 +65,7 @@ public class ExchangeNode extends PlanNode {
|
||||
private SortInfo mergeInfo;
|
||||
|
||||
private boolean isRightChildOfBroadcastHashJoin = false;
|
||||
private TPartitionType partitionType;
|
||||
|
||||
/**
|
||||
* use for Nereids only.
|
||||
@ -77,6 +79,10 @@ public class ExchangeNode extends PlanNode {
|
||||
computeTupleIds();
|
||||
}
|
||||
|
||||
public void setPartitionType(TPartitionType partitionType) {
|
||||
this.partitionType = partitionType;
|
||||
}
|
||||
|
||||
/**
|
||||
* Create ExchangeNode that consumes output of inputNode.
|
||||
* An ExchangeNode doesn't have an input node as a child, which is why we
|
||||
@ -171,6 +177,7 @@ public class ExchangeNode extends PlanNode {
|
||||
msg.exchange_node.setSortInfo(mergeInfo.toThrift());
|
||||
}
|
||||
msg.exchange_node.setOffset(offset);
|
||||
msg.exchange_node.setPartitionType(partitionType);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user