Reconnect to peers after connecting drops

This commit is contained in:
Vitaliy Filippov
2020-04-19 01:01:26 +03:00
parent dc57c5c362
commit 663153713b
3 changed files with 14 additions and 2 deletions
+5 -1
View File
@@ -365,8 +365,12 @@ void osd_t::stop_client(int peer_fd)
osd_client_t cl = it->second;
if (cl.osd_num)
{
// FIXME: Reload configuration from Consul when the connection is dropped
printf("[%lu] Stopping client %d (OSD peer %lu)\n", osd_num, peer_fd, cl.osd_num);
if (cl.peer_state == PEER_CONNECTED)
{
// Reload configuration from Consul when the connection is dropped
peer_states.erase(cl.osd_num);
}
}
else
{