diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-23 16:45:17 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-23 16:45:44 +0000 |
commit | 17d6a993fc17d533460c5f40f3908c708e057c18 (patch) | |
tree | 1a3bd93e0ecd74fa02f93a528fe2f87e5314c4b5 /src/rgw/rgw_bucket_layout.h | |
parent | Releasing progress-linux version 18.2.2-0progress7.99u1. (diff) | |
download | ceph-17d6a993fc17d533460c5f40f3908c708e057c18.tar.xz ceph-17d6a993fc17d533460c5f40f3908c708e057c18.zip |
Merging upstream version 18.2.3.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/rgw/rgw_bucket_layout.h')
-rw-r--r-- | src/rgw/rgw_bucket_layout.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/rgw/rgw_bucket_layout.h b/src/rgw/rgw_bucket_layout.h index 40aafd4dd..114f1f1ff 100644 --- a/src/rgw/rgw_bucket_layout.h +++ b/src/rgw/rgw_bucket_layout.h @@ -278,5 +278,14 @@ inline uint32_t current_num_shards(const BucketLayout& layout) { inline bool is_layout_indexless(const bucket_index_layout_generation& layout) { return layout.layout.type == BucketIndexType::Indexless; } +inline bool is_layout_reshardable(const bucket_index_layout_generation& layout) { + return layout.layout.type == BucketIndexType::Normal; +} +inline bool is_layout_reshardable(const BucketLayout& layout) { + return is_layout_reshardable(layout.current_index); +} +inline std::string_view current_layout_desc(const BucketLayout& layout) { + return rgw::to_string(layout.current_index.layout.type); +} } // namespace rgw |