From 19c56918b6030c724e8f1987b7a24b577737d1cf Mon Sep 17 00:00:00 2001 From: shen yushi Date: Thu, 12 Dec 2024 18:20:57 +0800 Subject: [PATCH] Fix compatible (#2362) ### What problem does this PR solve? Fix catalog json compatibility with older version. ### Type of change - [x] Bug Fix (non-breaking change which fixes an issue) --- src/storage/meta/entry/segment_index_entry.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/storage/meta/entry/segment_index_entry.cpp b/src/storage/meta/entry/segment_index_entry.cpp index ef3cf6e61c..cfb5b67b70 100644 --- a/src/storage/meta/entry/segment_index_entry.cpp +++ b/src/storage/meta/entry/segment_index_entry.cpp @@ -1212,7 +1212,7 @@ UniquePtr SegmentIndexEntry::Deserialize(const nlohmann::json segment_index_entry->ft_column_len_sum_ = index_entry_json["ft_column_len_sum"]; segment_index_entry->ft_column_len_cnt_ = index_entry_json["ft_column_len_cnt"]; - if (index_entry_json["deprecate_ts"].is_null() || index_entry_json["deprecate_ts"] == UNCOMMIT_TS) { + if (!index_entry_json.contains("deprecate_ts") || index_entry_json["deprecate_ts"] == UNCOMMIT_TS) { segment_index_entry->deleted_ = false; } else { segment_index_entry->deleted_ = true;