]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
osd: tell peers that ping us if they are dead
authorSage Weil <sage@inktank.com>
Wed, 29 May 2013 20:16:01 +0000 (13:16 -0700)
committerSage Weil <sage@inktank.com>
Wed, 29 May 2013 20:41:44 +0000 (13:41 -0700)
Signed-off-by: Sage Weil <sage@inktank.com>
src/osd/OSD.cc

index 26a601ed91a4a5eb76b99731854f29e74667e1ae..5c8457ac475121467ef51acbc5833a53e02821c2 100644 (file)
@@ -2417,6 +2417,13 @@ void OSD::handle_osd_ping(MOSDPing *m)
            _share_map_outgoing(from, con.get());
          }
        }
+      } else if (curmap->get_down_at(from) > m->map_epoch) {
+       // tell them they have died
+       Message *r = new MOSDPing(monc->get_fsid(),
+                                 curmap->get_epoch(),
+                                 MOSDPing::YOU_DIED,
+                                 m->stamp);
+       m->get_connection()->get_messenger()->send_message(r, m->get_connection());
       }
     }
     break;