Commit 9becfe32 authored by duanjinfei's avatar duanjinfei

update monitor nm heart time

parent 3d3a4faa
......@@ -199,9 +199,9 @@ func monitorWorker(op *operate.DockerOp) {
log.Info("------------------------Start rev msg worker thread------------------------")
for {
sub := time.Now().Sub(nodeManager.GetLastHeartTime())
sub := time.Now().Sub(nodeManager.GetLastHeartTime()).Seconds()
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).Seconds() {
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