You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by yi...@apache.org on 2024/02/05 14:01:14 UTC
(doris) 18/18: disable check segment when build rowset meta by default (#30857)
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
commit d123abc903b6835ddaae31b481c38eea19650e27
Author: HHoflittlefish777 <77...@users.noreply.github.com>
AuthorDate: Mon Feb 5 21:55:10 2024 +0800
disable check segment when build rowset meta by default (#30857)
---
be/src/common/config.cpp | 2 ++
be/src/common/config.h | 2 ++
be/src/olap/rowset/beta_rowset_writer.cpp | 2 +-
3 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/be/src/common/config.cpp b/be/src/common/config.cpp
index a11703a824e..873be1c5f5e 100644
--- a/be/src/common/config.cpp
+++ b/be/src/common/config.cpp
@@ -1180,6 +1180,8 @@ DEFINE_mDouble(high_disk_avail_level_diff_usages, "0.15");
// create tablet in partition random robin idx lru size, default 10000
DEFINE_Int32(partition_disk_index_lru_size, "10000");
+DEFINE_mBool(check_segment_when_build_rowset_meta, "false");
+
// clang-format off
#ifdef BE_TEST
// test s3
diff --git a/be/src/common/config.h b/be/src/common/config.h
index eaebffbd1eb..7aa18b0d614 100644
--- a/be/src/common/config.h
+++ b/be/src/common/config.h
@@ -1256,6 +1256,8 @@ DECLARE_mDouble(high_disk_avail_level_diff_usages);
// create tablet in partition random robin idx lru size, default 10000
DECLARE_Int32(partition_disk_index_lru_size);
+DECLARE_mBool(check_segment_when_build_rowset_meta);
+
#ifdef BE_TEST
// test s3
DECLARE_String(test_s3_resource);
diff --git a/be/src/olap/rowset/beta_rowset_writer.cpp b/be/src/olap/rowset/beta_rowset_writer.cpp
index ba6a8a11f97..991ad4a831b 100644
--- a/be/src/olap/rowset/beta_rowset_writer.cpp
+++ b/be/src/olap/rowset/beta_rowset_writer.cpp
@@ -643,7 +643,7 @@ Status BaseBetaRowsetWriter::_build_rowset_meta(std::shared_ptr<RowsetMeta> rows
}
auto segment_num = _num_seg();
- if (check_segment_num) {
+ if (check_segment_num && config::check_segment_when_build_rowset_meta) {
auto segments_encoded_key_bounds_size = segments_encoded_key_bounds.size();
if (segments_encoded_key_bounds_size != segment_num) {
return Status::InternalError(
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org