You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by hu...@apache.org on 2026/04/01 04:53:06 UTC
(doris) 01/01: [fix](local shuffle) fix NLJ COREDUMP: don't insert build-side BROADCAST for serial NLJ
This is an automated email from the ASF dual-hosted git repository.
huajianlan pushed a commit to branch fe_local_shuffle
in repository https://gitbox.apache.org/repos/asf/doris.git
commit d632320f8f6f5927ab3db501e80777b40fd587ad
Author: 924060929 <la...@selectdb.com>
AuthorDate: Wed Apr 1 12:23:14 2026 +0800
[fix](local shuffle) fix NLJ COREDUMP: don't insert build-side BROADCAST for serial NLJ
When NLJ is serial (RIGHT_OUTER/FULL_OUTER etc.), the probe pipeline has 1 task.
FE was inserting a BROADCAST local exchange on the build side for pooling scan,
which inflated the build pipeline's num_tasks to _num_instances. This caused
instance 1+ to create build tasks without corresponding probe tasks, leaving
source_deps empty and crashing in set_ready_to_read().
BE-native avoids this via the num_tasks_of_parent()<=1 check in _add_local_exchange.
Fix: set buildSideRequire to noRequire() for serial NLJ to match BE-native behavior.
---
.../java/org/apache/doris/planner/NestedLoopJoinNode.java | 11 +++++++----
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/fe/fe-core/src/main/java/org/apache/doris/planner/NestedLoopJoinNode.java b/fe/fe-core/src/main/java/org/apache/doris/planner/NestedLoopJoinNode.java
index 8bcb837e6da..4f3ecdea388 100644
--- a/fe/fe-core/src/main/java/org/apache/doris/planner/NestedLoopJoinNode.java
+++ b/fe/fe-core/src/main/java/org/apache/doris/planner/NestedLoopJoinNode.java
@@ -196,11 +196,14 @@ public class NestedLoopJoinNode extends JoinNodeBase {
} else if (isSerialOperator()) {
// RIGHT_OUTER/RIGHT_SEMI/RIGHT_ANTI/FULL_OUTER: probe side must be serial (1 task)
// to avoid duplicate unmatched rows from build side. No exchange needed for probe.
- // BE: NestedLoopJoinProbeOperatorX returns NOOP for these join types.
+ // Build side: noRequire() regardless of pooling scan. The probe pipeline has 1 task
+ // (serial), so inserting BROADCAST on the build side would inflate build pipeline's
+ // num_tasks to _num_instances while probe stays at 1. This causes instance 1+ to
+ // create build tasks without corresponding probe tasks, leaving source_deps empty
+ // and crashing in set_ready_to_read(). BE-native avoids this via the
+ // num_tasks_of_parent()<=1 check in _add_local_exchange.
probeSideRequire = LocalExchangeTypeRequire.noRequire();
- buildSideRequire = childUsePoolingScan
- ? LocalExchangeTypeRequire.requireBroadcast()
- : LocalExchangeTypeRequire.noRequire();
+ buildSideRequire = LocalExchangeTypeRequire.noRequire();
outputType = LocalExchangeType.NOOP;
} else if (childUsePoolingScan) {
probeSideRequire = LocalExchangeTypeRequire.requireAdaptivePassthrough();
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org