From 17d3c9f43f1df0f76b7365045d5dfbe3964e96ed Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Wed, 6 Jan 2016 21:34:09 -0500 Subject: [PATCH] os/ObjectStore: add collection_bits Signed-off-by: Sage Weil --- src/os/ObjectStore.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/os/ObjectStore.h b/src/os/ObjectStore.h index 5ba83bf373a44..b7239723c28df 100644 --- a/src/os/ObjectStore.h +++ b/src/os/ObjectStore.h @@ -2143,6 +2143,17 @@ public: */ virtual bool collection_empty(coll_t c) = 0; + /** + * return the number of significant bits of the coll_t::pgid. + * + * This should return what the last create_collection or split_collection + * set. A lazy backend can choose not to store and report this (e.g., + * FileStore). + */ + virtual int collection_bits(coll_t c) { + return -EOPNOTSUPP; + } + /** * list contents of a collection that fall in the range [start, end) and no more than a specified many result * @@ -2160,6 +2171,7 @@ public: bool sort_bitwise, int max, vector *ls, ghobject_t *next) = 0; + /// OMAP /// Get omap contents virtual int omap_get( -- 2.39.5