[fix](vresultsink) BufferControlBlock may block all fragment handle threads (#16231)

BufferControlBlock may block all fragment handle threads leads to be out of work

modify include:

BufferControlBlock cancel after max timeout
StmtExcutor notify be to cancel the fragment when unexcepted occur
more details see issue #16203
This commit is contained in:
chenlinzhong
2023-01-30 16:53:21 +08:00
committed by GitHub
parent 342f3168b5
commit fdc042bb39
7 changed files with 26 additions and 5 deletions

View File

@ -101,7 +101,8 @@ Status VResultFileSink::prepare(RuntimeState* state) {
if (_is_top_sink) {
// create sender
RETURN_IF_ERROR(state->exec_env()->result_mgr()->create_sender(
state->fragment_instance_id(), _buf_size, &_sender, state->enable_pipeline_exec()));
state->fragment_instance_id(), _buf_size, &_sender, state->enable_pipeline_exec(),
state->query_timeout()));
// create writer
_writer.reset(new (std::nothrow) VFileResultWriter(
_file_opts.get(), _storage_type, state->fragment_instance_id(), _output_vexpr_ctxs,

View File

@ -62,7 +62,8 @@ Status VResultSink::prepare(RuntimeState* state) {
// create sender
RETURN_IF_ERROR(state->exec_env()->result_mgr()->create_sender(
state->fragment_instance_id(), _buf_size, &_sender, state->enable_pipeline_exec()));
state->fragment_instance_id(), _buf_size, &_sender, state->enable_pipeline_exec(),
state->query_timeout()));
// create writer based on sink type
switch (_sink_type) {