]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
client: flush cap release on session flush 26082/head
authorPatrick Donnelly <pdonnell@redhat.com>
Tue, 22 Jan 2019 18:44:26 +0000 (10:44 -0800)
committerPatrick Donnelly <pdonnell@redhat.com>
Tue, 22 Jan 2019 18:56:14 +0000 (10:56 -0800)
MDS expects the completed cap release prior to responding to the session flush
for cache drop.

Fixes: http://tracker.ceph.com/issues/38009
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
src/client/Client.cc

index a0b54d3dc10d7505e6e529944c91ab2762e344af..af720ac155fe047e8f29083eb5a6a88a2e1809b5 100644 (file)
@@ -2142,6 +2142,10 @@ void Client::handle_client_session(const MConstRef<MClientSession>& m)
     break;
 
   case CEPH_SESSION_FLUSHMSG:
+    /* flush cap release */
+    if (auto& m = session->release; m) {
+      session->con->send_message2(std::move(m));
+    }
     session->con->send_message2(MClientSession::create(CEPH_SESSION_FLUSHMSG_ACK, m->get_seq()));
     break;