summaryrefslogtreecommitdiff
path: root/src/messages
diff options
context:
space:
mode:
authorSage Weil <sage.weil@dreamhost.com>2011-12-30 10:43:33 -0800
committerSage Weil <sage.weil@dreamhost.com>2011-12-30 10:43:33 -0800
commit7969cc4f28625863af15ae1f158085d5ee33f939 (patch)
treeff91ba109d3cbd882c5c7638e7ce24821ed59416 /src/messages
parent959fd71f69f28ee964e6530d953f8f190aa1e147 (diff)
parent0d9507c2b0b04a76a95e888853b87d9d986f6760 (diff)
downloadceph-7969cc4f28625863af15ae1f158085d5ee33f939.tar.gz
Merge remote branch 'gh/master' into wip-backfill
Diffstat (limited to 'src/messages')
-rw-r--r--src/messages/MAuth.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/messages/MAuth.h b/src/messages/MAuth.h
index 2d16cf66cb7..631f80cef49 100644
--- a/src/messages/MAuth.h
+++ b/src/messages/MAuth.h
@@ -20,17 +20,19 @@
struct MAuth : public PaxosServiceMessage {
__u32 protocol;
bufferlist auth_payload;
+ epoch_t monmap_epoch;
/* if protocol == 0, then auth_payload is a set<__u32> listing protocols the client supports */
- MAuth() : PaxosServiceMessage(CEPH_MSG_AUTH, 0), protocol(0) { }
+ MAuth() : PaxosServiceMessage(CEPH_MSG_AUTH, 0), protocol(0), monmap_epoch(0) { }
private:
~MAuth() {}
public:
const char *get_type_name() { return "auth"; }
void print(ostream& out) {
- out << "auth(proto " << protocol << " " << auth_payload.length() << " bytes)";
+ out << "auth(proto " << protocol << " " << auth_payload.length() << " bytes"
+ << " epoch " << monmap_epoch << ")";
}
void decode_payload(CephContext *cct) {
@@ -38,11 +40,16 @@ public:
paxos_decode(p);
::decode(protocol, p);
::decode(auth_payload, p);
+ if (!p.end())
+ ::decode(monmap_epoch, p);
+ else
+ monmap_epoch = 0;
}
void encode_payload(CephContext *cct) {
paxos_encode();
::encode(protocol, payload);
::encode(auth_payload, payload);
+ ::encode(monmap_epoch, payload);
}
bufferlist& get_auth_payload() { return auth_payload; }
};