[Optimize](kill-query)Support the scanners exits as soon as possible when kill query #29803

This commit is contained in:
Xujian Duan
2024-01-11 20:47:42 +08:00
committed by yiguolei
parent d494674ff4
commit ad2c13e009

View File

@ -282,6 +282,7 @@ void VFileScanner::_get_slot_ids(VExpr* expr, std::vector<int>* slot_ids) {
}
Status VFileScanner::open(RuntimeState* state) {
RETURN_IF_CANCELLED(state);
RETURN_IF_ERROR(VScanner::open(state));
RETURN_IF_ERROR(_init_expr_ctxes());
@ -309,6 +310,7 @@ Status VFileScanner::open(RuntimeState* state) {
// _convert_to_output_block - - - - - - x
Status VFileScanner::_get_block_impl(RuntimeState* state, Block* block, bool* eof) {
do {
RETURN_IF_CANCELLED(state);
if (_cur_reader == nullptr || _cur_reader_eof) {
RETURN_IF_ERROR(_get_next_reader());
}