You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by mo...@apache.org on 2023/02/05 04:11:51 UTC
[doris] 09/15: [bugfix](disk balance) fix new rowset time check when add tablet (#16261)
This is an automated email from the ASF dual-hosted git repository.
morningman pushed a commit to branch branch-1.2-lts
in repository https://gitbox.apache.org/repos/asf/doris.git
commit 69e99daf30f8e82028998c9e4d20ebb637791433
Author: yixiutt <10...@users.noreply.github.com>
AuthorDate: Fri Feb 3 21:49:37 2023 +0800
[bugfix](disk balance) fix new rowset time check when add tablet (#16261)
In disk balancer, if a tablet is in highly concurrent load,
new rowset creation time(which use current time) may be same as the
newest rowset, and when add tablet, there has a creation time check
that new_time must bigger than old time, so disk balancer will failed
many times and makes this tablet lose many verisons as migration will
block writes.
---
be/src/olap/tablet_manager.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/be/src/olap/tablet_manager.cpp b/be/src/olap/tablet_manager.cpp
index 23c3e7c72c..9d111dd697 100644
--- a/be/src/olap/tablet_manager.cpp
+++ b/be/src/olap/tablet_manager.cpp
@@ -156,7 +156,7 @@ Status TabletManager::_add_tablet_unlocked(TTabletId tablet_id, const TabletShar
// here, the new rowset's file will also be dropped, so use keep files here
bool keep_files = force ? true : false;
if (force ||
- (new_version > old_version || (new_version == old_version && new_time > old_time))) {
+ (new_version > old_version || (new_version == old_version && new_time >= old_time))) {
// check if new tablet's meta is in store and add new tablet's meta to meta store
res = _add_tablet_to_map_unlocked(tablet_id, tablet, update_meta, keep_files,
true /*drop_old*/);
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org