github-actions[bot] commented on code in PR #64366:
URL: https://github.com/apache/doris/pull/64366#discussion_r3413013973
##########
fe/fe-core/src/main/java/org/apache/doris/nereids/load/NereidsBrokerLoadTask.java:
##########
@@ -25,12 +25,14 @@
import org.apache.doris.thrift.TFileFormatType;
import org.apache.doris.thrift.TFileType;
+import java.time.Instant;
import java.util.List;
/**
* Nereids Broker Load Task
*/
public class NereidsBrokerLoadTask implements NereidsLoadTaskInfo {
+ private final Instant statementStartTime = Instant.now();
Review Comment:
This broker-load timestamp is not the one later sent to BE. In
`NereidsLoadingTaskPlanner.plan()`, the thread-local `ConnectContext` statement
context is created or left in place before this `NereidsBrokerLoadTask` is
constructed, so `NereidsLoadPlanInfoCollector` folds/prunes with this field
while `LoadLoadingTask.executeOnce()` later calls
`EnvFactory.createCoordinator()`, which derives `TQueryGlobals` from
`ConnectContext.get().getStatementContext().getStatementStartTime()`. If that
context was created just before this object, or reused from a previous
scheduler operation, broker-load predicates/partition pruning can use one
instant while BE evaluates runtime `now()` with another. This is distinct from
the existing stream-load thread because broker load uses
`NereidsLoadingTaskPlanner` plus `EnvFactory.createCoordinator`, not
`NereidsStreamLoadPlanner.createQueryGlobals()`. Please install this same
timestamp into the `ConnectContext` used by broker-load coordinator construction
, or pass it explicitly into `createCoordinator()`.
--
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]