From 464f39cdf4cf2299dc44d7ceff41df0d30ab827c Mon Sep 17 00:00:00 2001 From: obdev Date: Wed, 23 Oct 2024 14:49:36 +0000 Subject: [PATCH] =?UTF-8?q?4251=E5=9C=A8master=E5=8D=A0=E4=BD=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- deps/oblib/src/common/ob_version_def.h | 2 ++ src/share/ob_upgrade_utils.cpp | 3 +++ src/share/ob_upgrade_utils.h | 3 ++- 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/deps/oblib/src/common/ob_version_def.h b/deps/oblib/src/common/ob_version_def.h index 3a95f8ae63..4bd8ec87ac 100644 --- a/deps/oblib/src/common/ob_version_def.h +++ b/deps/oblib/src/common/ob_version_def.h @@ -126,6 +126,7 @@ cal_version(const uint64_t major, const uint64_t minor, const uint64_t major_pat #define MOCK_CLUSTER_VERSION_4_2_3_1 (oceanbase::common::cal_version(4, 2, 3, 1)) #define MOCK_CLUSTER_VERSION_4_2_4_0 (oceanbase::common::cal_version(4, 2, 4, 0)) #define MOCK_CLUSTER_VERSION_4_2_5_0 (oceanbase::common::cal_version(4, 2, 5, 0)) +#define MOCK_CLUSTER_VERSION_4_2_5_1 (oceanbase::common::cal_version(4, 2, 5, 1)) // new data version before 4.3 cannot upgrade to master, must add "MOCK_" prefix #define CLUSTER_VERSION_4_3_0_0 (oceanbase::common::cal_version(4, 3, 0, 0)) #define CLUSTER_VERSION_4_3_0_1 (oceanbase::common::cal_version(4, 3, 0, 1)) @@ -164,6 +165,7 @@ cal_version(const uint64_t major, const uint64_t minor, const uint64_t major_pat #define MOCK_DATA_VERSION_4_2_3_1 (oceanbase::common::cal_version(4, 2, 3, 1)) #define MOCK_DATA_VERSION_4_2_4_0 (oceanbase::common::cal_version(4, 2, 4, 0)) #define MOCK_DATA_VERSION_4_2_5_0 (oceanbase::common::cal_version(4, 2, 5, 0)) +#define MOCK_DATA_VERSION_4_2_5_1 (oceanbase::common::cal_version(4, 2, 5, 1)) // new data version before 4.3 cannot upgrade to master, must add "MOCK_" prefix #define DATA_VERSION_4_3_0_0 (oceanbase::common::cal_version(4, 3, 0, 0)) #define DATA_VERSION_4_3_0_1 (oceanbase::common::cal_version(4, 3, 0, 1)) diff --git a/src/share/ob_upgrade_utils.cpp b/src/share/ob_upgrade_utils.cpp index 5cd11cb1f9..e48866b053 100755 --- a/src/share/ob_upgrade_utils.cpp +++ b/src/share/ob_upgrade_utils.cpp @@ -56,6 +56,7 @@ const uint64_t ObUpgradeChecker::UPGRADE_PATH[] = { CALC_VERSION(4UL, 2UL, 3UL, 1UL), // 4.2.3.1 CALC_VERSION(4UL, 2UL, 4UL, 0UL), // 4.2.4.0 CALC_VERSION(4UL, 2UL, 5UL, 0UL), // 4.2.5.0 + CALC_VERSION(4UL, 2UL, 5UL, 1UL), // 4.2.5.1 CALC_VERSION(4UL, 3UL, 0UL, 0UL), // 4.3.0.0 CALC_VERSION(4UL, 3UL, 0UL, 1UL), // 4.3.0.1 CALC_VERSION(4UL, 3UL, 1UL, 0UL), // 4.3.1.0 @@ -92,6 +93,7 @@ int ObUpgradeChecker::get_data_version_by_cluster_version( CONVERT_CLUSTER_VERSION_TO_DATA_VERSION(MOCK_CLUSTER_VERSION_4_2_3_1, MOCK_DATA_VERSION_4_2_3_1) CONVERT_CLUSTER_VERSION_TO_DATA_VERSION(MOCK_CLUSTER_VERSION_4_2_4_0, MOCK_DATA_VERSION_4_2_4_0) CONVERT_CLUSTER_VERSION_TO_DATA_VERSION(MOCK_CLUSTER_VERSION_4_2_5_0, MOCK_DATA_VERSION_4_2_5_0) + CONVERT_CLUSTER_VERSION_TO_DATA_VERSION(MOCK_CLUSTER_VERSION_4_2_5_1, MOCK_DATA_VERSION_4_2_5_1) CONVERT_CLUSTER_VERSION_TO_DATA_VERSION(CLUSTER_VERSION_4_3_0_0, DATA_VERSION_4_3_0_0) CONVERT_CLUSTER_VERSION_TO_DATA_VERSION(CLUSTER_VERSION_4_3_0_1, DATA_VERSION_4_3_0_1) CONVERT_CLUSTER_VERSION_TO_DATA_VERSION(CLUSTER_VERSION_4_3_1_0, DATA_VERSION_4_3_1_0) @@ -688,6 +690,7 @@ int ObUpgradeProcesserSet::init( INIT_PROCESSOR_BY_VERSION(4, 2, 3, 1); INIT_PROCESSOR_BY_VERSION(4, 2, 4, 0); INIT_PROCESSOR_BY_VERSION(4, 2, 5, 0); + INIT_PROCESSOR_BY_VERSION(4, 2, 5, 1); INIT_PROCESSOR_BY_VERSION(4, 3, 0, 0); INIT_PROCESSOR_BY_VERSION(4, 3, 0, 1); INIT_PROCESSOR_BY_VERSION(4, 3, 1, 0); diff --git a/src/share/ob_upgrade_utils.h b/src/share/ob_upgrade_utils.h index 271a4f670e..72c6429e5f 100755 --- a/src/share/ob_upgrade_utils.h +++ b/src/share/ob_upgrade_utils.h @@ -176,7 +176,7 @@ public: const uint64_t cluster_version, uint64_t &data_version); public: - static const int64_t DATA_VERSION_NUM = 23; + static const int64_t DATA_VERSION_NUM = 24; static const uint64_t UPGRADE_PATH[]; }; @@ -245,6 +245,7 @@ DEF_SIMPLE_UPGRARD_PROCESSER(4, 2, 3, 0) DEF_SIMPLE_UPGRARD_PROCESSER(4, 2, 3, 1) DEF_SIMPLE_UPGRARD_PROCESSER(4, 2, 4, 0) DEF_SIMPLE_UPGRARD_PROCESSER(4, 2, 5, 0) +DEF_SIMPLE_UPGRARD_PROCESSER(4, 2, 5, 1) DEF_SIMPLE_UPGRARD_PROCESSER(4, 3, 0, 0) DEF_SIMPLE_UPGRARD_PROCESSER(4, 3, 0, 1)