]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr/ClusterState: report health about pgs
authorSage Weil <sage@redhat.com>
Tue, 16 May 2017 17:27:00 +0000 (13:27 -0400)
committerSage Weil <sage@redhat.com>
Fri, 2 Jun 2017 17:02:10 +0000 (13:02 -0400)
Signed-off-by: Sage Weil <sage@redhat.com>
src/mgr/ClusterState.cc

index 9a498e9584754a2c2a10d28a3fd4b758c63f82c4..3ec59c170787470055656e989e4441b272093707 100644 (file)
@@ -116,9 +116,16 @@ void ClusterState::notify_osdmap(const OSDMap &osd_map)
 
 void ClusterState::tick(MMonMgrReport *m)
 {
-  dout(0) << __func__ << dendl;
+  dout(10) << __func__ << dendl;
   // FIXME: no easy way to get mon features here.  this will do for
   // now, though, as long as we don't make a backward-incompat change.
   pg_map.encode_digest(m->get_data(), CEPH_FEATURES_ALL);
+
+  // FIXME: reporting health detail here might be a bad idea?
+  with_osdmap([&](const OSDMap& osdmap) {
+      pg_map.get_health(g_ceph_context, osdmap,
+                       m->health_summary,
+                       &m->health_detail);
+    });
   m->needs_send = true;
 }