This is an automated email from the ASF dual-hosted git repository.

yiguolei pushed a commit to branch branch-2.1
in repository https://gitbox.apache.org/repos/asf/doris.git


The following commit(s) were added to refs/heads/branch-2.1 by this push:
     new a81beb19c2b [fix](load) fix repeatedly open tablets_channel when 
tablets_channel already cancelled (#34442)
a81beb19c2b is described below

commit a81beb19c2b2ad2d258f8cfc389e6edeb1e0a9de
Author: Xin Liao <[email protected]>
AuthorDate: Mon May 6 23:14:42 2024 +0800

    [fix](load) fix repeatedly open tablets_channel when tablets_channel 
already cancelled (#34442)
---
 be/src/runtime/tablets_channel.cpp | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/be/src/runtime/tablets_channel.cpp 
b/be/src/runtime/tablets_channel.cpp
index ad6a7f73c49..7ed0a9a8e05 100644
--- a/be/src/runtime/tablets_channel.cpp
+++ b/be/src/runtime/tablets_channel.cpp
@@ -127,8 +127,9 @@ void TabletsChannel::_init_profile(RuntimeProfile* profile) 
{
 
 Status BaseTabletsChannel::open(const PTabletWriterOpenRequest& request) {
     std::lock_guard<std::mutex> l(_lock);
-    if (_state == kOpened) {
-        // Normal case, already open by other sender
+    // if _state is kOpened, it's a normal case, already open by other sender
+    // if _state is kFinished, already cancelled by other sender
+    if (_state == kOpened || _state == kFinished) {
         return Status::OK();
     }
     LOG(INFO) << "open tablets channel: " << _key << ", tablets num: " << 
request.tablets().size()


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to