]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
osdc/Objecter: resend command map version checks on reconnect
authorSage Weil <sage@inktank.com>
Tue, 2 Jul 2013 20:43:29 +0000 (13:43 -0700)
committerSage Weil <sage@inktank.com>
Tue, 2 Jul 2013 20:43:29 +0000 (13:43 -0700)
We already do this for Ops and LingerOps, but missed this when we added
CommandOps to the mix.  The result is that an ill-timed mon disconnect will
leave a command map check (and thus the command) hanging.

This misbehavior was introduced when CommandOp was introduced, back in
commit 2e172225b01561bb7988b6d86d96ff4b9c1c5762, and we failed to fix it
in 8808ca57c652502d9cf803b0dc53673ca9dd62af.

Fixes: #5493
Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Josh Durgin <josh.durgin@inktank.com>
src/osdc/Objecter.cc

index f5e997ad67fdf5ce26cca4d922718b627709075f..1dfeb36e0305bf8a3877176f2adeaa5bd80318a0 100644 (file)
@@ -1131,6 +1131,13 @@ void Objecter::resend_mon_ops()
     C_Linger_Map_Latest *c = new C_Linger_Map_Latest(this, p->second->linger_id);
     monc->get_version("osdmap", &c->latest, NULL, c);
   }
+
+  for (map<uint64_t, CommandOp*>::iterator p = check_latest_map_commands.begin();
+       p != check_latest_map_commands.end();
+       ++p) {
+    C_Command_Map_Latest *c = new C_Command_Map_Latest(this, p->second->tid);
+    monc->get_version("osdmap", &c->latest, NULL, c);
+  }
 }