Commit 3d3a4faa authored by duanjinfei's avatar duanjinfei

add monitor nm heart time

parent 7a7b9d69
......@@ -201,7 +201,7 @@ func monitorWorker(op *operate.DockerOp) {
for {
sub := time.Now().Sub(nodeManager.GetLastHeartTime())
log.WithField("time(uint seconds)", sub).Info("The time difference since the last heartbeat")
if sub == time.Duration(conf.GetConfig().HeartRespTimeSecond) {
if sub > time.Duration(conf.GetConfig().HeartRespTimeSecond) {
if nodeManager.Status {
nodeManager.UpdateStatus(false)
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment