What is the default value of initialDelaySeconds

喜夏-厌秋 提交于 2019-11-30 18:41:38

It seems that the default value of 0 is missing from the documentation.

The health or readiness check algorithm works like this:

  1. Wait for initialDelaySeconds
  2. Perform readiness check and wait timeoutSeconds for a timeout
  3. If the number of continued successes is greater than successThreshold return success
    If the number of continued failures is greater than failureThreshold return failure
    otherwise wait periodSeconds and start a new readiness check

Given the pace at which the project changes, I wanted to make sure the code actually confirms this.

Found a test in the public Kubernetes repo that verifies the default settings for probes:

    expectedProbe := v1.Probe{
        InitialDelaySeconds: 0,
        TimeoutSeconds:      1,
        PeriodSeconds:       10,
        SuccessThreshold:    1,
        FailureThreshold:    3,
    }

See method TestSetDefaultProbe in

https://github.com/kubernetes/kubernetes/blob/master/pkg/apis/core/v1/defaults_test.go

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!