}
}
+void PGMap::print_summary(ceph::Formatter *f, ostream *out) const
+{
+ if (f) {
+ f->open_array_section("pgs_by_pool_state");
+ for (auto& i: num_pg_by_pool_state) {
+ f->open_object_section("per_pool_pgs_by_state");
+ f->dump_int("pool_id", i.first);
+ f->open_array_section("pg_state_counts");
+ for (auto& j : i.second) {
+ f->open_object_section("pg_state_count");
+ f->dump_string("state_name", pg_state_string(j.first));
+ f->dump_int("count", j.second);
+ f->close_section();
+ }
+ f->close_section();
+ f->close_section();
+ }
+ f->close_section();
+ }
+ PGMapDigest::print_summary(f, out);
+}
+
int process_pg_map_command(
const string& orig_prefix,
const cmdmap_t& orig_cmdmap,
CephContext *cct,
const OSDMap& osdmap,
health_check_map_t *checks) const;
+ void print_summary(ceph::Formatter *f, ostream *out) const;
static void generate_test_instances(std::list<PGMap*>& o);
};