From 9d73f277c3c83ee19ee55889cbc77fc4b32f6b5b Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 5 Dec 2024 19:16:45 +0800 Subject: [PATCH] branch-3.0: [Fix](merge-on-write) Should clear `GetDeleteBitmapUpdateLockResponse` when geting delete bitmap update lock fail and retry #44975 (#45010) Cherry-picked from #44975 Co-authored-by: bobhan1 --- cloud/src/meta-service/meta_service_helper.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/cloud/src/meta-service/meta_service_helper.h b/cloud/src/meta-service/meta_service_helper.h index 5355ac0eb61ed2..e4ed7e2a231901 100644 --- a/cloud/src/meta-service/meta_service_helper.h +++ b/cloud/src/meta-service/meta_service_helper.h @@ -118,6 +118,12 @@ void finish_rpc(std::string_view func_name, brpc::Controller* ctrl, Response* re << " status=" << res->status().ShortDebugString() << " tablet=" << res->tablet_id() << " delete_bitmap_count=" << res->segment_delete_bitmaps_size(); + } else if constexpr (std::is_same_v) { + if (res->status().code() != MetaServiceCode::OK) { + res->clear_base_compaction_cnts(); + res->clear_cumulative_compaction_cnts(); + res->clear_cumulative_points(); + } } else if constexpr (std::is_same_v || std::is_same_v) { std::string debug_string = res->DebugString();