From: Sage Weil Date: Wed, 4 Dec 2013 22:46:40 +0000 (-0800) Subject: os/ObjectStore: pass cct to ctor X-Git-Tag: v0.74~24^2~4 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=a70200e329ccd9aca26f6577ff1d7725b557cf8c;p=ceph.git os/ObjectStore: pass cct to ctor Signed-off-by: Sage Weil --- diff --git a/src/ceph_osd.cc b/src/ceph_osd.cc index 2b74fe9e8210..ae7a919ce4bd 100644 --- a/src/ceph_osd.cc +++ b/src/ceph_osd.cc @@ -163,7 +163,8 @@ int main(int argc, const char **argv) } // the store - ObjectStore *store = ObjectStore::create(g_conf->osd_objectstore, + ObjectStore *store = ObjectStore::create(g_ceph_context, + g_conf->osd_objectstore, g_conf->osd_data, g_conf->osd_journal); if (!store) { diff --git a/src/os/ObjectStore.cc b/src/os/ObjectStore.cc index 0e7a039b020e..07466f1c2502 100644 --- a/src/os/ObjectStore.cc +++ b/src/os/ObjectStore.cc @@ -19,7 +19,8 @@ #include "FileStore.h" #include "common/safe_io.h" -ObjectStore *ObjectStore::create(const string& type, +ObjectStore *ObjectStore::create(CephContext *cct, + const string& type, const string& data, const string& journal) { diff --git a/src/os/ObjectStore.h b/src/os/ObjectStore.h index 3494afd2b2b6..8aa47f82a704 100644 --- a/src/os/ObjectStore.h +++ b/src/os/ObjectStore.h @@ -31,6 +31,8 @@ #include /* or */ #endif /* DARWIN */ +class CephContext; + using std::vector; using std::string; @@ -77,7 +79,7 @@ static inline void encode(const map *attrset, bufferlist &bl) } class ObjectStore { -private: +protected: string path; public: @@ -88,7 +90,8 @@ public: * @param data path (or other descriptor) for data * @param journal path (or other descriptor) for journal (optional) */ - static ObjectStore *create(const string& type, + static ObjectStore *create(CephContext *cct, + const string& type, const string& data, const string& journal);