]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mon: show feature flags when printing MonSession 22773/head
authorPaul Emmerich <paul.emmerich@oocero.de>
Wed, 6 Sep 2017 22:43:06 +0000 (00:43 +0200)
committerNathan Cutler <ncutler@suse.com>
Fri, 29 Jun 2018 14:53:50 +0000 (16:53 +0200)
allows identifying clients using older releases with
the 'sessions' mon command

Signed-off-by: Paul Emmerich <paul.emmerich@croit.io>
(cherry picked from commit fe1e24bd56282fdcb670db94476bddff94fcf438)

src/mon/Session.h

index 6dddee0716b05a9fb367bd24fade7581405767bd..9b54f962264f94a69f8f3d8012c3c1a4b8bf2f3e 100644 (file)
@@ -225,9 +225,10 @@ struct MonSessionMap {
 
 inline ostream& operator<<(ostream& out, const MonSession& s)
 {
-  out << "MonSession(" << s.inst << " is "
-      << (s.closed ? "closed" : "open");
-  out << " " << s.caps << ")";
+  out << "MonSession(" << s.inst << " is " << (s.closed ? "closed" : "open")
+      << " " << s.caps << ", features 0x" << std::hex << s.con_features << std::dec
+      <<  " (" << ceph_release_name(ceph_release_from_features(s.con_features))
+      << "))";
   return out;
 }