From: Sage Weil Date: Thu, 1 Jun 2017 20:47:27 +0000 (-0400) Subject: os/ObjectStore: is_rotational() interface X-Git-Tag: v12.1.0~249^2~5 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=66fe04bffc0208588daf72662bdb795079ec676a;p=ceph.git os/ObjectStore: is_rotational() interface Signed-off-by: Sage Weil --- diff --git a/src/os/ObjectStore.h b/src/os/ObjectStore.h index 9c760a91c4457..71f5e80b17c5f 100644 --- a/src/os/ObjectStore.h +++ b/src/os/ObjectStore.h @@ -1561,6 +1561,20 @@ public: virtual bool wants_journal() = 0; //< prefers a journal virtual bool allows_journal() = 0; //< allows a journal + /** + * is_rotational + * + * Check whether store is backed by a rotational (HDD) or non-rotational + * (SSD) device. + * + * This must be usable *before* the store is mounted. + * + * @return true for HDD, false for SSD + */ + virtual bool is_rotational() { + return true; + } + virtual bool can_sort_nibblewise() { return false; // assume a backend cannot, unless it says otherwise }