MINOR: checks: fix agent check interval computation
start_checks() only used to consider the health checks intervals to
compute the start interval, so if an agent had a faster check than
all health checks, it would be significantly delayed.
diff --git a/src/checks.c b/src/checks.c
index ec05781..9d906bd 100644
--- a/src/checks.c
+++ b/src/checks.c
@@ -1771,6 +1771,11 @@
(!mininter || mininter > srv_getinter(&s->check)))
mininter = srv_getinter(&s->check);
+ if ((s->agent.state & CHK_ST_CONFIGURED) &&
+ (srv_getinter(&s->agent) >= SRV_CHK_INTER_THRES) &&
+ (!mininter || mininter > srv_getinter(&s->agent)))
+ mininter = srv_getinter(&s->agent);
+
nbcheck++;
}
}