MCPcopy Create free account
hub / github.com/ceph/ceph / dump

Method dump

src/mds/SimpleLock.cc:70–95  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

68}
69
70void SimpleLock::dump(ceph::Formatter *f) const {
71 ceph_assert(f != NULL);
72 if (is_sync_and_unlocked()) {
73 return;
74 }
75
76 f->open_array_section("gather_set");
77 if (have_more()) {
78 for(const auto &i : more()->gather_set) {
79 f->dump_int("rank", i);
80 }
81 }
82 f->close_section();
83
84 f->dump_string("state", get_state_name(get_state()));
85 f->dump_string("type", get_lock_type_name(get_type()));
86 f->dump_bool("is_leased", is_leased());
87 f->dump_int("num_rdlocks", get_num_rdlocks());
88 f->dump_int("num_wrlocks", get_num_wrlocks());
89 f->dump_int("num_xlocks", get_num_xlocks());
90 f->open_object_section("xlock_by");
91 if (auto mut = get_xlock_by(); mut) {
92 f->dump_object("reqid", mut->reqid);
93 }
94 f->close_section();
95}
96
97std::list<SimpleLock> SimpleLock::generate_test_instances() {
98 std::list<SimpleLock> ls;

Callers

nothing calls this directly

Calls 9

get_stateFunction · 0.85
get_typeFunction · 0.85
open_array_sectionMethod · 0.45
dump_intMethod · 0.45
close_sectionMethod · 0.45
dump_stringMethod · 0.45
dump_boolMethod · 0.45
open_object_sectionMethod · 0.45
dump_objectMethod · 0.45

Tested by

no test coverage detected