diff --git a/be/src/runtime/buffer_control_block.cpp b/be/src/runtime/buffer_control_block.cpp index 6f4427746f8103..b9697fb72ed989 100644 --- a/be/src/runtime/buffer_control_block.cpp +++ b/be/src/runtime/buffer_control_block.cpp @@ -170,7 +170,10 @@ BufferControlBlock::BufferControlBlock(TUniqueId id, int buffer_size, RuntimeSta } BufferControlBlock::~BufferControlBlock() { - cancel(Status::Cancelled("Cancelled")); + cancel(Status::Cancelled(fmt::format( + "BufferControlBlock is destructed, this is not the expected path, the correct path is " + "ResultBufferMgr::cancel before the destructor, fragmentId: {}", + print_id(_fragment_id)))); } Status BufferControlBlock::init() { diff --git a/be/src/runtime/result_buffer_mgr.cpp b/be/src/runtime/result_buffer_mgr.cpp index 5756fd267851fe..e33cc766bc03f3 100644 --- a/be/src/runtime/result_buffer_mgr.cpp +++ b/be/src/runtime/result_buffer_mgr.cpp @@ -211,7 +211,8 @@ void ResultBufferMgr::cancel_thread() { // cancel query for (const auto& id : query_to_cancel) { - cancel(id, Status::TimedOut("Query tiemout")); + cancel(id, Status::Cancelled(fmt::format( + "Clean up expired BufferControlBlock, queryId: {}", print_id(id)))); } } while (!_stop_background_threads_latch.wait_for(std::chrono::seconds(1)));