From: Kefu Chai Date: Thu, 27 Sep 2018 12:40:22 +0000 (+0800) Subject: msg/async: keep connection alive only actually sending X-Git-Tag: v14.0.1~153^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=c316f821807f8fe9eb71982b7ed93b99acd0bfcd;p=ceph.git msg/async: keep connection alive only actually sending When connection stuck into odd state, we need to let connection timeout. If send_message could update last_active, it won't play the role as expected. So we move last_active updated to the place actually should. Signed-off-by: Haomai Wang Signed-off-by: Kefu Chai --- diff --git a/src/msg/async/AsyncConnection.cc b/src/msg/async/AsyncConnection.cc index cf2110d92a541..6e42ad95ecbc4 100644 --- a/src/msg/async/AsyncConnection.cc +++ b/src/msg/async/AsyncConnection.cc @@ -513,7 +513,6 @@ int AsyncConnection::send_message(Message *m) return 0; } - last_active = ceph::coarse_mono_clock::now(); // we don't want to consider local message here, it's too lightweight which // may disturb users logger->inc(l_msgr_send_messages);