]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
osd/OpRequest: fix reqid assignment for reply messages 17060/head
authorYingxin <yingxin.cheng@intel.com>
Thu, 17 Aug 2017 14:41:40 +0000 (10:41 -0400)
committerYingxin <yingxin.cheng@intel.com>
Thu, 17 Aug 2017 16:40:35 +0000 (12:40 -0400)
Signed-off-by: Yingxin Cheng <yingxin.cheng@intel.com>
src/osd/OpRequest.cc

index 4a85a2c5610b54257dd0bbbc464434b76e75b7ce..b6e20949624dc0b1a80c1b22174ffa957f7f13fc 100644 (file)
@@ -9,7 +9,9 @@
 #include "msg/Message.h"
 #include "messages/MOSDOp.h"
 #include "messages/MOSDSubOp.h"
+#include "messages/MOSDSubOpReply.h"
 #include "messages/MOSDRepOp.h"
+#include "messages/MOSDRepOpReply.h"
 #include "include/assert.h"
 #include "osd/osd_types.h"
 
@@ -36,8 +38,12 @@ OpRequest::OpRequest(Message *req, OpTracker *tracker) :
     reqid = static_cast<MOSDOp*>(req)->get_reqid();
   } else if (req->get_type() == MSG_OSD_SUBOP) {
     reqid = static_cast<MOSDSubOp*>(req)->reqid;
+  } else if (req->get_type() == MSG_OSD_SUBOPREPLY) {
+    reqid = static_cast<MOSDSubOpReply*>(req)->reqid;
   } else if (req->get_type() == MSG_OSD_REPOP) {
     reqid = static_cast<MOSDRepOp*>(req)->reqid;
+  } else if (req->get_type() == MSG_OSD_REPOPREPLY) {
+    reqid = static_cast<MOSDRepOpReply*>(req)->reqid;
   }
   req_src_inst = req->get_source_inst();
   mark_event("header_read", request->get_recv_stamp());