This is an automated email from the ASF dual-hosted git repository.
dataroaring pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/doris.git
The following commit(s) were added to refs/heads/master by this push:
new 269c1b189d5 [improve](vtablet_writer) check runtime state is cancel
when back pressure (#29260)
269c1b189d5 is described below
commit 269c1b189d55d0c342180052932649fb7b22413a
Author: HHoflittlefish777 <[email protected]>
AuthorDate: Fri Dec 29 09:11:24 2023 +0800
[improve](vtablet_writer) check runtime state is cancel when back pressure
(#29260)
---
be/src/vec/sink/writer/vtablet_writer.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/be/src/vec/sink/writer/vtablet_writer.cpp
b/be/src/vec/sink/writer/vtablet_writer.cpp
index 3093dbc5f6b..40b1c544e23 100644
--- a/be/src/vec/sink/writer/vtablet_writer.cpp
+++ b/be/src/vec/sink/writer/vtablet_writer.cpp
@@ -478,7 +478,7 @@ Status VNodeChannel::add_block(vectorized::Block* block,
const Payload* payload,
// But there is still some unfinished things, we do mem limit here
temporarily.
// _cancelled may be set by rpc callback, and it's possible that
_cancelled might be set in any of the steps below.
// It's fine to do a fake add_block() and return OK, because we will check
_cancelled in next add_block() or mark_close().
- while (!_cancelled && _pending_batches_num > 0 &&
+ while (!_cancelled && !_state->is_cancelled() && _pending_batches_num > 0
&&
_pending_batches_bytes > _max_pending_batches_bytes) {
SCOPED_RAW_TIMER(&_stat.mem_exceeded_block_ns);
std::this_thread::sleep_for(std::chrono::milliseconds(10));
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]