]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mds: allow handling slave request in the clientreplay stage
authorYan, Zheng <zheng.z.yan@intel.com>
Sun, 27 Jan 2013 07:16:19 +0000 (15:16 +0800)
committerYan, Zheng <zheng.z.yan@intel.com>
Tue, 29 Jan 2013 02:17:37 +0000 (10:17 +0800)
replaying a client request may need to create slave request and the slave
MDS can be also in the clientreplay stage.

Signed-off-by: Yan, Zheng <zheng.z.yan@intel.com>
src/mds/Server.cc

index 9d08c202c67a1ee535d8c1b31a8ecc4a99c8aa26..04bcba712297afdf7ce7dc0d83db7f84589faa81 100644 (file)
@@ -101,6 +101,10 @@ void Server::dispatch(Message *m)
                (m->get_type() == CEPH_MSG_CLIENT_REQUEST &&
                 ((MClientRequest*)m)->is_replay()))) {
       // replaying!
+    } else if (mds->is_clientreplay() && m->get_type() == MSG_MDS_SLAVE_REQUEST &&
+              (((MMDSSlaveRequest*)m)->is_reply() ||
+               !mds->mdsmap->is_active(m->get_source().num()))) {
+      // slave reply or the master is also in the clientreplay stage
     } else {
       dout(3) << "not active yet, waiting" << dendl;
       mds->wait_for_active(new C_MDS_RetryMessage(mds, m));