924060929 commented on code in PR #69683:
URL: https://github.com/apache/doris/pull/69683#discussion_r4396361514


##########
be/src/exec/scan/split_source_connector.cpp:
##########
@@ -48,26 +48,36 @@ Status RemoteSplitSourceConnector::get_next(bool* has_next, 
TFileRangeDesc* rang
     *has_next = false;
     if (_scan_index == _scan_ranges.size() && !_last_batch) {
         SCOPED_TIMER(_get_split_timer);
-        Status coord_status;
-        // No need to set timeout because on FE side, there is a max fetch time
-        FrontendServiceConnection 
coord(_state->exec_env()->frontend_client_cache(),
-                                        _state->get_query_ctx()->coord_addr, 
&coord_status);
-        RETURN_IF_ERROR(coord_status);
         TFetchSplitBatchRequest request;
         request.__set_split_source_id(_split_source_id);
         request.__set_max_num_splits(config::remote_split_source_batch_size);
         TFetchSplitBatchResult result;
-        try {
-            coord->fetchSplitBatch(result, request);
-            if (result.__isset.status && result.status.status_code != 
TStatusCode::OK) {
-                return Status::IOError<false>("Failed to get batch of split 
source: {}",
-                                              result.status.error_msgs.empty()
-                                                      ? "unknown error"
-                                                      : 
result.status.error_msgs[0]);
+        do {
+            RETURN_IF_CANCELLED(_state);

Review Comment:
   Fixed in 1f23f5b6a46. Scanner::try_stop now publishes an atomic local stop 
signal, and FileScanner/FileScannerV2 pass it to the shared 
SplitSourceConnector. RemoteSplitSourceConnector checks it before each 
pending-response retry and returns no next range when a local LIMIT stops that 
scanner, even if RuntimeState and other query branches remain active. The new 
BE test covers a locally stopped scanner with an uncancelled RuntimeState. 
Header hygiene, clang-format 16, and diff checks pass. Local BE compilation and 
the test were blocked at CMake compiler-link detection by this Mac’s unaccepted 
Xcode license; buildall CI has been requested.



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