From d42a27f961a198ac596df142a41494c37eb098be Mon Sep 17 00:00:00 2001 From: 007gzs <007gzs@gmail.com> Date: Wed, 21 Aug 2024 18:36:07 +0800 Subject: [PATCH 1/2] target_file_size_base_ to int64_t --- include/pika_conf.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/pika_conf.h b/include/pika_conf.h index 02e765719e..6941738bcf 100644 --- a/include/pika_conf.h +++ b/include/pika_conf.h @@ -270,7 +270,7 @@ class PikaConf : public pstd::BaseConf { std::shared_lock l(rwlock_); return compression_; } - int target_file_size_base() { + int64_t target_file_size_base() { std::shared_lock l(rwlock_); return target_file_size_base_; } @@ -1027,7 +1027,7 @@ class PikaConf : public pstd::BaseConf { // Critical configure items // bool write_binlog_ = false; - int target_file_size_base_ = 0; + int64_t target_file_size_base_ = 0; int64_t max_compaction_bytes_ = 0; int binlog_file_size_ = 0; From 09bc481dca52c0f4154c68bfca4df0a811d04f02 Mon Sep 17 00:00:00 2001 From: 007gzs <007gzs@gmail.com> Date: Wed, 21 Aug 2024 18:37:45 +0800 Subject: [PATCH 2/2] GetConfInt64Human --- src/pika_conf.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pika_conf.cc b/src/pika_conf.cc index 9c0f5751af..98468835e8 100644 --- a/src/pika_conf.cc +++ b/src/pika_conf.cc @@ -421,7 +421,7 @@ int PikaConf::Load() { } // target_file_size_base - GetConfIntHuman("target-file-size-base", &target_file_size_base_); + GetConfInt64Human("target-file-size-base", &target_file_size_base_); if (target_file_size_base_ <= 0) { target_file_size_base_ = 1048576; // 10Mb }