You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@inlong.apache.org by do...@apache.org on 2021/09/20 01:55:14 UTC

[incubator-inlong] branch master updated: [INLONG-1568]C++ SDK cant not return the whether the partition has been registered correctly (#1576)

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

dockerzhang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-inlong.git


The following commit(s) were added to refs/heads/master by this push:
     new 822669a  [INLONG-1568]C++ SDK cant not return the whether the partition has been registered correctly (#1576)
822669a is described below

commit 822669ae46ba2b9ba35e6bec88b155dd11f925db
Author: gosonzhang <46...@qq.com>
AuthorDate: Mon Sep 20 09:55:08 2021 +0800

    [INLONG-1568]C++ SDK cant not return the whether the partition has been registered correctly (#1576)
---
 .../tubemq-client-twins/tubemq-client-cpp/src/rmt_data_cache.cc        | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/inlong-tubemq/tubemq-client-twins/tubemq-client-cpp/src/rmt_data_cache.cc b/inlong-tubemq/tubemq-client-twins/tubemq-client-cpp/src/rmt_data_cache.cc
index 029a736..db72231 100644
--- a/inlong-tubemq/tubemq-client-twins/tubemq-client-cpp/src/rmt_data_cache.cc
+++ b/inlong-tubemq/tubemq-client-twins/tubemq-client-cpp/src/rmt_data_cache.cc
@@ -456,7 +456,8 @@ bool RmtDataCacheCsm::IsPartitionFirstReg(const string& partition_key) {
   lock_guard<mutex> lck(data_book_mutex_);
   it = part_reg_booked_.find(partition_key);
   if (it == part_reg_booked_.end()) {
-    part_reg_booked_[partition_key] = true;
+    part_reg_booked_[partition_key] = false;
+    return true;
   }
   return part_reg_booked_[partition_key];
 }