Skip to content

Commit

Permalink
[fix](cloud) unify empty_partition_prune condition with nereids (#34861)
Browse files Browse the repository at this point in the history
  • Loading branch information
freemandealer authored May 15, 2024
1 parent 8af8910 commit 2b11827
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
import org.apache.doris.cloud.proto.Cloud.MetaServiceCode;
import org.apache.doris.cloud.rpc.VersionHelper;
import org.apache.doris.common.profile.SummaryProfile;
import org.apache.doris.nereids.rules.RuleType;
import org.apache.doris.qe.ConnectContext;
import org.apache.doris.qe.StmtExecutor;
import org.apache.doris.rpc.RpcException;
Expand Down Expand Up @@ -334,7 +335,8 @@ private static Cloud.GetVersionResponse getVersionFromMeta(Cloud.GetVersionReque

private static boolean isEmptyPartitionPruneDisabled() {
ConnectContext ctx = ConnectContext.get();
if (ctx != null && ctx.getSessionVariable().getDisableEmptyPartitionPrune()) {
if (ctx != null && (ctx.getSessionVariable().getDisableNereidsRules().get(RuleType.valueOf(
"PRUNE_EMPTY_PARTITION").type()) || ctx.getSessionVariable().getDisableEmptyPartitionPrune())) {
return true;
}
return false;
Expand Down

0 comments on commit 2b11827

Please sign in to comment.