github-actions[bot] commented on code in PR #38243:
URL: https://github.com/apache/doris/pull/38243#discussion_r1708573142


##########
cloud/src/meta-service/txn_lazy_committer.cpp:
##########
@@ -0,0 +1,212 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements.  See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership.  The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License.  You may obtain a copy of the License at
+//
+//   http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied.  See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+#include "txn_lazy_committer.h"
+
+#include "common/logging.h"
+#include "common/util.h"
+#include "meta-service/keys.h"
+#include "meta-service/meta_service_helper.h"
+
+namespace doris::cloud {
+
+void scan_tmp_rowset(
+        const std::string& instance_id, int64_t txn_id, std::shared_ptr<TxnKv> 
txn_kv,
+        MetaServiceCode& code, std::string& msg, int64_t* db_id,
+        std::vector<std::pair<std::string, doris::RowsetMetaCloudPB>>* 
tmp_rowsets_meta);
+
+void convert_tmp_rowsets(
+        const std::string& instance_id, int64_t txn_id, std::shared_ptr<TxnKv> 
txn_kv,
+        MetaServiceCode& code, std::string& msg, int64_t db_id,
+        std::vector<std::pair<std::string, doris::RowsetMetaCloudPB>>& 
tmp_rowsets_meta,
+        std::unordered_map<int64_t, TabletIndexPB>& tablet_ids);
+
+void make_committed_txn_visible(const std::string& instance_id, int64_t db_id, 
int64_t txn_id,
+                                std::shared_ptr<TxnKv> txn_kv, 
MetaServiceCode& code,
+                                std::string& msg);
+
+TxnLazyCommitTask::TxnLazyCommitTask(const std::string& instance_id, int64_t 
txn_id,
+                                     std::shared_ptr<TxnKv> txn_kv,
+                                     TxnLazyCommitter* txn_lazy_committer)
+        : instance_id_(instance_id),
+          txn_id_(txn_id),
+          txn_kv_(txn_kv),
+          txn_lazy_committer_(txn_lazy_committer) {
+    DCHECK(txn_id > 0);
+}
+
+void TxnLazyCommitTask::commit() {

Review Comment:
   warning: function 'commit' exceeds recommended size/complexity thresholds 
[readability-function-size]
   ```cpp
   void TxnLazyCommitTask::commit() {
                           ^
   ```
   <details>
   <summary>Additional context</summary>
   
   **cloud/src/meta-service/txn_lazy_committer.cpp:51:** 122 lines including 
whitespace and comments (threshold 80)
   ```cpp
   void TxnLazyCommitTask::commit() {
                           ^
   ```
   
   </details>
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to