[fix](group commit) Pick make group commit cancel in time (#36249) (#37404)

pick https://github.com/apache/doris/pull/36249/
This commit is contained in:
meiyi
2024-07-09 09:25:11 +08:00
committed by GitHub
parent 1a25270918
commit 1e3ab0ff8c
2 changed files with 56 additions and 1 deletions

View File

@ -142,7 +142,7 @@ Status LoadBlockQueue::get_block(RuntimeState* runtime_state, vectorized::Block*
<< ", runtime_state=" << runtime_state;
}
}
_get_cond.wait_for(l, std::chrono::milliseconds(left_milliseconds));
_get_cond.wait_for(l, std::chrono::milliseconds(std::min(left_milliseconds, 10000L)));
}
if (runtime_state->is_cancelled()) {
auto st = Status::Cancelled<false>(runtime_state->cancel_reason());