From aa51a738d5603593645d7a1814ee251b053653fc Mon Sep 17 00:00:00 2001 From: "zihe.liu" Date: Mon, 2 Sep 2024 19:09:52 +0800 Subject: [PATCH] [Enhancement] Log only finish operator non-cancel error by cancelling (backport #50454) (#50549) Signed-off-by: zihe.liu --- be/src/exec/pipeline/pipeline_driver.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/be/src/exec/pipeline/pipeline_driver.cpp b/be/src/exec/pipeline/pipeline_driver.cpp index 497e59530278a..41f40d1f6a796 100644 --- a/be/src/exec/pipeline/pipeline_driver.cpp +++ b/be/src/exec/pipeline/pipeline_driver.cpp @@ -695,10 +695,11 @@ Status PipelineDriver::_mark_operator_finished(OperatorPtr& op, RuntimeState* st Status PipelineDriver::_mark_operator_cancelled(OperatorPtr& op, RuntimeState* state) { Status res = _mark_operator_finished(op, state); - if (!res.ok()) { - LOG(WARNING) << fmt::format("fragment_id {} driver {} cancels operator {} with finished error {}", - print_id(state->fragment_instance_id()), to_readable_string(), op->get_name(), - res.get_error_msg()); + if (!res.ok() && !res.is_cancelled()) { + LOG(WARNING) << fmt::format( + "[Driver] failed to finish operator called by cancelling operator [fragment_id={}] [driver={}] " + "[operator={}] [error={}]", + print_id(state->fragment_instance_id()), to_readable_string(), op->get_name(), res.get_error_msg()); } auto& op_state = _operator_stages[op->get_id()]; if (op_state >= OperatorStage::CANCELLED) {