]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mds: add stream dump for LogSegment
authorPatrick Donnelly <pdonnell@redhat.com>
Thu, 3 Nov 2022 14:30:53 +0000 (10:30 -0400)
committerPatrick Donnelly <pdonnell@redhat.com>
Tue, 1 Aug 2023 15:16:00 +0000 (11:16 -0400)
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
src/mds/LogSegment.h

index 405760c47a83ed2eb8ed363c4c78f45ca64c03d8..0fbb824b348e6c009b0fc6c81679bce7d6f8975f 100644 (file)
@@ -106,4 +106,9 @@ class LogSegment {
   MDSContext::vec expiry_waiters;
 };
 
+static inline std::ostream& operator<<(std::ostream& out, const LogSegment& ls) {
+  return out << "LogSegment(" << ls.seq << "/0x" << std::hex << ls.offset
+             << std::dec << " events=" << ls.num_events << ")";
+}
+
 #endif