summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/mds/MDSTableServer.cc2
-rw-r--r--src/mds/MDSTableServer.h27
-rw-r--r--src/mds/mdstypes.h26
3 files changed, 28 insertions, 27 deletions
diff --git a/src/mds/MDSTableServer.cc b/src/mds/MDSTableServer.cc
index 7175bbb3cfe..6eadd82a500 100644
--- a/src/mds/MDSTableServer.cc
+++ b/src/mds/MDSTableServer.cc
@@ -156,7 +156,7 @@ void MDSTableServer::handle_mds_recovery(int who)
dout(7) << "handle_mds_recovery mds." << who << dendl;
// resend agrees for recovered mds
- for (map<version_t,_pending>::iterator p = pending_for_mds.begin();
+ for (map<version_t,mds_table_pending_t>::iterator p = pending_for_mds.begin();
p != pending_for_mds.end();
p++) {
if (who >= 0 && p->second.mds != who)
diff --git a/src/mds/MDSTableServer.h b/src/mds/MDSTableServer.h
index 1467263d8b7..26cd5944844 100644
--- a/src/mds/MDSTableServer.h
+++ b/src/mds/MDSTableServer.h
@@ -22,31 +22,7 @@ class MMDSTableRequest;
class MDSTableServer : public MDSTable {
public:
int table;
-
- /* mds's requesting any pending ops. child needs to encodig the corresponding
- * pending mutation state in the table.
- */
- struct _pending {
- uint64_t reqid;
- __s32 mds;
- version_t tid;
- void encode(bufferlist& bl) const {
- __u8 struct_v = 1;
- ::encode(struct_v, bl);
- ::encode(reqid, bl);
- ::encode(mds, bl);
- ::encode(tid, bl);
- }
- void decode(bufferlist::iterator& bl) {
- __u8 struct_v;
- ::decode(struct_v, bl);
- ::decode(reqid, bl);
- ::decode(mds, bl);
- ::decode(tid, bl);
- }
- };
- WRITE_CLASS_ENCODER(_pending)
- map<version_t,_pending> pending_for_mds; // ** child should encode this! **
+ map<version_t,mds_table_pending_t> pending_for_mds; // ** child should encode this! **
private:
@@ -117,6 +93,5 @@ private:
void finish_recovery();
void handle_mds_recovery(int who);
};
-WRITE_CLASS_ENCODER(MDSTableServer::_pending)
#endif
diff --git a/src/mds/mdstypes.h b/src/mds/mdstypes.h
index c9c30e3488e..32439ffaffd 100644
--- a/src/mds/mdstypes.h
+++ b/src/mds/mdstypes.h
@@ -615,6 +615,32 @@ inline ostream& operator<<(ostream& out, const string_snap_t &k)
return out << "(" << k.name << "," << k.snapid << ")";
}
+/*
+ * mds_table_pending_t
+ *
+ * mds's requesting any pending ops. child needs to encode the corresponding
+ * pending mutation state in the table.
+ */
+struct mds_table_pending_t {
+ uint64_t reqid;
+ __s32 mds;
+ version_t tid;
+ void encode(bufferlist& bl) const {
+ __u8 struct_v = 1;
+ ::encode(struct_v, bl);
+ ::encode(reqid, bl);
+ ::encode(mds, bl);
+ ::encode(tid, bl);
+ }
+ void decode(bufferlist::iterator& bl) {
+ __u8 struct_v;
+ ::decode(struct_v, bl);
+ ::decode(reqid, bl);
+ ::decode(mds, bl);
+ ::decode(tid, bl);
+ }
+};
+WRITE_CLASS_ENCODER(mds_table_pending_t)
// =========