]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
os/bluestore: Get rid of some Onode constructors
authorAdam Kupczyk <akupczyk@ibm.com>
Mon, 9 Dec 2024 18:49:09 +0000 (18:49 +0000)
committerAdam Kupczyk <akupczyk@ibm.com>
Mon, 31 Mar 2025 07:32:43 +0000 (07:32 +0000)
We had 3 constructors that do basically the same.

Signed-off-by: Adam Kupczyk <akupczyk@ibm.com>
src/os/bluestore/BlueStore.cc
src/os/bluestore/BlueStore.h

index 02dcdca07c3c0e3a88a097fc21ea34fefc7867fb..b47bb61ef7c799dc0bf6acc21f5ed0f550bd2e7a 100644 (file)
@@ -4843,7 +4843,7 @@ BlueStore::Onode* BlueStore::Onode::create_decode(
   bool allow_empty)
 {
   ceph_assert(v.length() || allow_empty);
-  Onode* on = new Onode(c.get(), oid, key);
+  Onode* on = new Onode(c.get(), oid, (const mempool::bluestore_cache_meta::string)(key));
 
   if (v.length()) {
     ExtentMap::ExtentDecoderFull edecoder(on->extent_map);
index f636808ead8e6ba2faa294570137906707db7485..a2cf4705cf63938732769cc0682824da11486b51 100644 (file)
@@ -1381,30 +1381,6 @@ public:
            bluestore_extent_map_inline_shard_prealloc_size),
        bc(*this) {
     }
-    Onode(Collection* c, const ghobject_t& o,
-      const std::string& k)
-      : c(c),
-        oid(o),
-        key(k),
-        exists(false),
-        cached(false),
-        extent_map(this,
-         c->store->cct->_conf->
-           bluestore_extent_map_inline_shard_prealloc_size),
-       bc(*this) {
-    }
-    Onode(Collection* c, const ghobject_t& o,
-      const char* k)
-      : c(c),
-        oid(o),
-        key(k),
-        exists(false),
-        cached(false),
-        extent_map(this,
-         c->store->cct->_conf->
-           bluestore_extent_map_inline_shard_prealloc_size),
-       bc(*this) {
-    }
     Onode(CephContext* cct)
       : c(nullptr),
         exists(false),