Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
import org.apache.doris.planner.JoinNodeBase;
import org.apache.doris.planner.RuntimeFilter.RuntimeFilterTarget;
import org.apache.doris.planner.ScanNode;
import org.apache.doris.qe.ConnectContext;
import org.apache.doris.qe.SessionVariable;
import org.apache.doris.thrift.TRuntimeFilterType;

Expand Down Expand Up @@ -108,6 +109,11 @@ public Expr visitSlotReference(SlotReference slotReference, PlanTranslatorContex
* @param ctx plan translator context
*/
public void createLegacyRuntimeFilter(RuntimeFilter filter, JoinNodeBase node, PlanTranslatorContext ctx) {
if (ConnectContext.get() != null
&& ConnectContext.get().getSessionVariable()
.getIgnoredRuntimeFilterIds().contains(filter.getId().asInt())) {
return;
}
Expr src = ExpressionTranslator.translate(filter.getSrcExpr(), ctx);
List<Expr> targetExprList = new ArrayList<>();
List<Map<TupleId, List<SlotId>>> targetTupleIdMapList = new ArrayList<>();
Expand Down
24 changes: 24 additions & 0 deletions fe/fe-core/src/main/java/org/apache/doris/qe/SessionVariable.java
Original file line number Diff line number Diff line change
Expand Up @@ -1181,6 +1181,30 @@ public void setMaxJoinNumberOfReorder(int maxJoinNumberOfReorder) {
description = {"是否启用更快的浮点数转换算法,注意会影响输出格式", "Set true to enable faster float pointer number convert"})
public boolean fasterFloatConvert = false;

@VariableMgr.VarAttr(name = IGNORE_RUNTIME_FILTER_IDS,
description = {"在IGNORE_RUNTIME_FILTER_IDS列表中的runtime filter将不会被生成",
"the runtime filter id in IGNORE_RUNTIME_FILTER_IDS list will not be generated"})

public String ignoreRuntimeFilterIds = "";
public static final String IGNORE_RUNTIME_FILTER_IDS = "ignore_runtime_filter_ids";

public Set<Integer> getIgnoredRuntimeFilterIds() {
return Arrays.stream(ignoreRuntimeFilterIds.split(",[\\s]*"))
.map(v -> {
int res = -1;
try {
res = Integer.valueOf(v);
} catch (Exception e) {
//ignore it
}
return res;
}).collect(ImmutableSet.toImmutableSet());
}

public void setIgnoreRuntimeFilterIds(String ignoreRuntimeFilterIds) {
this.ignoreRuntimeFilterIds = ignoreRuntimeFilterIds;
}

public static final String IGNORE_SHAPE_NODE = "ignore_shape_nodes";

public Set<String> getIgnoreShapePlanNodes() {
Expand Down