This commit is contained in:
yuyulei
2020-11-23 11:38:21 +08:00
committed by GitHub
parent a85bd9a4d9
commit 127a31ea6a
7 changed files with 53 additions and 31 deletions

View File

@ -408,7 +408,7 @@ func (ctl *Control) manager() {
for {
select {
case <-heartbeat.C:
if time.Since(ctl.lastPing) > time.Duration(ctl.serverCfg.HeartBeatTimeout)*time.Second {
if time.Since(ctl.lastPing) > time.Duration(ctl.serverCfg.HeartbeatTimeout)*time.Second {
xl.Warn("heartbeat timeout")
return
}