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

Class MClientRequest

src/messages/MClientRequest.h:89–413  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

87// metadata ops.
88
89class MClientRequest final : public MMDSOp {
90private:
91 static constexpr int HEAD_VERSION = 6;
92 static constexpr int COMPAT_VERSION = 1;
93
94public:
95 mutable struct ceph_mds_request_head head; /* XXX HACK! */
96 utime_t stamp;
97 feature_bitset_t mds_features;
98
99 struct Release {
100 mutable ceph_mds_request_release item;
101 std::string dname;
102
103 Release() : item(), dname() {}
104 Release(const ceph_mds_request_release& rel, std::string name) :
105 item(rel), dname(name) {}
106
107 void encode(ceph::buffer::list& bl) const {
108 using ceph::encode;
109 item.dname_len = dname.length();
110 encode(item, bl);
111 ceph::encode_nohead(dname, bl);
112 }
113 void decode(ceph::buffer::list::const_iterator& bl) {
114 using ceph::decode;
115 decode(item, bl);
116 ceph::decode_nohead(item.dname_len, dname, bl);
117 }
118
119 void dump(ceph::Formatter *f) const {
120 f->dump_string("dname", dname);
121 f->dump_unsigned("ino", item.ino);
122 f->dump_unsigned("cap_id", item.cap_id);
123 f->dump_unsigned("caps", item.caps);
124 f->dump_unsigned("wanted", item.wanted);
125 f->dump_unsigned("seq", item.seq);
126 f->dump_unsigned("issue_seq", item.issue_seq);
127 f->dump_unsigned("mseq", item.mseq);
128 f->dump_unsigned("dname_seq", item.dname_seq);
129 f->dump_unsigned("dname_len", item.dname_len);
130 }
131
132 static std::list<Release> generate_test_instances() {
133 std::list<Release> ls;
134 ls.emplace_back();
135 ls.emplace_back();
136 ls.back().item.dname_len = 4;
137 ls.back().dname = "test";
138 return ls;
139 }
140 };
141 mutable std::vector<Release> releases; /* XXX HACK! */
142
143 // path arguments
144 filepath path, path2;
145 std::string alternate_name;
146 std::vector<uint64_t> gid_list;

Callers

nothing calls this directly

Calls 1

get_pathMethod · 0.45

Tested by

no test coverage detected