You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by GitBox <gi...@apache.org> on 2020/08/23 14:40:06 UTC

[GitHub] [incubator-doris] morningman commented on a change in pull request #4401: [Bug-Fix] Some deleted tablets are not recycled on BE

morningman commented on a change in pull request #4401:
URL: https://github.com/apache/incubator-doris/pull/4401#discussion_r475222531



##########
File path: be/src/olap/tablet_manager.cpp
##########
@@ -1086,6 +1094,52 @@ OLAPStatus TabletManager::start_trash_sweep() {
     return OLAP_SUCCESS;
 } // start_trash_sweep
 
+void TabletManager::register_clone_tablet(int64_t tablet_id) {
+    RWMutex& tablet_map_lock = _get_tablet_map_lock(tablet_id);
+    ReadLock rlock(&tablet_map_lock);
+    _tablets_under_clone.insert(tablet_id);
+}
+
+void TabletManager::unregister_clone_tablet(int64_t tablet_id) {
+    RWMutex& tablet_map_lock = _get_tablet_map_lock(tablet_id);
+    ReadLock rlock(&tablet_map_lock);

Review comment:
       Should it be WriteLock?




----------------------------------------------------------------
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.

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



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