tools/ceph-objectstore-tool: dump onode internal metadata.
[ceph.git] / src / os / ObjectStore.h
index 1ac2e0746f572235e9b041212d0aa65b867d441c..cb84be8faa4fb16dfae5d44436809f2f06113a6c 100644 (file)
@@ -1705,6 +1705,24 @@ public:
    virtual int fiemap(CollectionHandle& c, const ghobject_t& oid,
                      uint64_t offset, size_t len, std::map<uint64_t, uint64_t>& destmap) = 0;
 
+  /**
+   * dump_onode -- dumps onode metadata in human readable form,
+     intended primiarily for debugging
+   *
+   * @param cid collection for object
+   * @param oid oid of object
+   * @param section_name section name to create and print under
+   * @param f Formatter class instance to print to
+   * @returns 0 on success, negative error code on failure.
+   */
+  virtual int dump_onode(
+    CollectionHandle &c,
+    const ghobject_t& oid,
+    const string& section_name,
+    Formatter *f) {
+    return -ENOTSUP;
+  }
+
   /**
    * getattr -- get an xattr of an object
    *