github-actions[bot] commented on code in PR #65837:
URL: https://github.com/apache/doris/pull/65837#discussion_r3774162130


##########
fe/fe-core/src/main/java/org/apache/doris/nereids/glue/translator/RuntimeFilterTranslator.java:
##########
@@ -249,6 +249,11 @@ private void 
createLegacyRuntimeFilterFromGroup(List<RuntimeFilter> group,
                             RuntimeFilterPartitionPruneClassifier.classify(
                                     head.getType(), targetExpr, 
nereidsTargetExprList.get(i), scanNode);
                     setPartitionPruningMetadata(origFilter, scanNode, 
classification);
+                    RuntimeFilterBucketPruneClassifier.Classification 
bucketClassification =

Review Comment:
   [P2] Pin the grouped target-identity protocol in a translator-level test. 
Bucket eligibility is keyed only by filter ID and scan-node ID, so correctness 
relies on the different-target/cast suppression and finalized target map 
staying aligned. The classifier unit bypasses grouping/finalization/Thrift, 
while the regression covers only an ordinary single target. Please cover 
same-scan same/different targets, cast or non-identity suppression, and 
enabled/disabled serialization, asserting both planId_to_target_expr and 
bucket_pruning_target_ids.



##########
regression-test/suites/query_p0/runtime_filter/rf_bucket_pruning.groovy:
##########
@@ -0,0 +1,136 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements.  See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership.  The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License.  You may obtain a copy of the License at
+//
+//   http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied.  See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+import org.apache.doris.regression.action.ProfileAction
+
+suite("rf_bucket_pruning", "nonConcurrent") {
+    sql "set enable_runtime_filter_prune=false"
+    sql "set enable_runtime_filter_partition_prune=false"
+    sql "set enable_runtime_filter_bucket_prune=true"
+    sql "set runtime_filter_wait_infinitely=true"
+    sql "set runtime_filter_type='IN'"
+    sql "set disable_join_reorder=true"
+    sql "set enable_profile=true"
+    sql "set profile_level=2"
+    sql "set parallel_pipeline_task_num=1"

Review Comment:
   [P2] Exercise the late/parallel pruning lifecycle. This suite waits 
indefinitely for the RF and forces one pipeline task, while the BE unit calls 
the pruner directly. Consequently none of the changed scheduler 
pre/post-prepare checks or late publication path is covered. Please add a 
deterministic multi-task test that starts the probe before an exact filter 
becomes READY, synchronizes publication with scanner scheduling, and asserts 
both correct rows and a positive pruning counter.



##########
fe/fe-core/src/main/java/org/apache/doris/nereids/glue/translator/RuntimeFilterTranslator.java:
##########
@@ -249,6 +249,11 @@ private void 
createLegacyRuntimeFilterFromGroup(List<RuntimeFilter> group,
                             RuntimeFilterPartitionPruneClassifier.classify(
                                     head.getType(), targetExpr, 
nereidsTargetExprList.get(i), scanNode);
                     setPartitionPruningMetadata(origFilter, scanNode, 
classification);
+                    RuntimeFilterBucketPruneClassifier.Classification 
bucketClassification =
+                            
RuntimeFilterBucketPruneClassifier.classify(head.getType(), targetExpr, 
scanNode);

Review Comment:
   [P2] Avoid bucket classification when the feature is disabled. Both 
translator paths scan every selected partition before the session flag is 
consulted during later serialization, so SET 
enable_runtime_filter_bucket_prune=false still pays O(filters x partitions) 
catalog work whose result is discarded. Please gate the classifier/marking 
before this call so the disable switch also removes the new planning overhead.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to