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


##########
fe/fe-core/src/main/java/org/apache/doris/nereids/glue/translator/RuntimeFilterTranslator.java:
##########
@@ -317,6 +317,23 @@ public void createLegacyRuntimeFilter(RuntimeFilter 
filter, PlanNode node, PlanT
                 }
                 origFilter.setBitmapFilterNotIn(filter.isBitmapFilterNotIn());
                 
origFilter.setBloomFilterSizeCalculatedByNdv(filter.isBloomFilterSizeCalculatedByNdv());
+                if (filter.isNonBlocking()) {
+                    origFilter.setWaitTimeMs(0);
+                } else {
+                    if (ConnectContext.get() != null) {
+                        SessionVariable sessionVar = 
ConnectContext.get().getSessionVariable();
+                        if (sessionVar.runtimeFilterWaitInfinitely
+                                || origFilter.getType() == 
TRuntimeFilterType.BITMAP
+                                || !origFilter.hasRemoteTargets()) {

Review Comment:
   `origFilter.hasRemoteTargets()` is still false here because target locality 
is only populated later in `finalize()` via `extractTargetsPosition()`. As a 
result every non-nonBlocking single-target RF enters this branch and gets 
`query_timeout * 1000` as `wait_time_ms`, so remote filters no longer honor 
`runtime_filter_wait_time_ms` and can block scans until the query timeout. This 
same new wait-time policy also is not applied in 
`createLegacyRuntimeFilterFromGroup`, so grouped RFs behave differently. Please 
compute/extract target locality before this decision (or derive it directly 
from `scanNodeList` vs `node.getFragmentId()`) and share the logic with the 
grouped path before serializing `wait_time_ms`.



-- 
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