In Kubernetes Kubernetes Health Check Probes
, what happens if timeoutSeconds
exceeds periodSeconds
? For example:
initialDelaySeconds: 10
periodSeconds: 5
timeoutSeconds: 10
successThreshold: 1
failureThreshold: 3
When will the Pod "fail"?
initialDelaySeconds
+ (periodSeconds
* failureThreshold
); orinitialDelaySeconds
+ ( MAX
(periodSeconds
,timeoutSeconds
) * failureThreshold
);Same question applies for when the Pod succeeds.
There is a diagram in this blog post which illustrate your question clearly:
The pod will be restarted at lowest,
time = initialDelay + (failureThreshold - 1) * period + timeout
timeoutSeconds
> periodSeconds
?The probe call will be fired at a given interval independent of the previous probe response. The failureThreshold
will be checked, once the probe call is passed or failed/timeout. But it is recommended to use periodSeconds
greater than the timeoutSeconds
.