• 003_Readiness gates详解


    一、

    使用kubectl get pods -o wide可以看到有一列字段为"READINESS GATES"

    详解如下:

    FEATURE STATE: Kubernetes v1.14 [stable]

    Your application can inject extra feedback or signals into PodStatus: Pod readiness. To use this, set readinessGates in the Pod's spec to specify a list of additional conditions that the kubelet evaluates for Pod readiness.

    Readiness gates are determined by the current state of status.condition fields for the Pod. If Kubernetes cannot find such a condition in the status.conditions field of a Pod, the status of the condition is defaulted to "False".

    Here is an example:

    kind: Pod
    ...
    spec:
      readinessGates:
        - conditionType: "www.example.com/feature-1"
    status:
      conditions:
        - type: Ready                              # a built in PodCondition
          status: "False"
          lastProbeTime: null
          lastTransitionTime: 2018-01-01T00:00:00Z
        - type: "www.example.com/feature-1"        # an extra PodCondition
          status: "False"
          lastProbeTime: null
          lastTransitionTime: 2018-01-01T00:00:00Z
      containerStatuses:
        - containerID: docker://abcd...
          ready: true
    ...
    

    Reference: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#pod-readiness-gate

  • 相关阅读:
    数据库(DB)
    PHP课程设计
    版本号设计规则
    设计模式(Java)
    简单的流式布局(移动应用开发)
    laravel工作机制(PHP程序设计)
    接口自动化测试(软件测试)
    Java学习路线
    ES6基础知识
    promise
  • 原文地址:https://www.cnblogs.com/itcomputer/p/16723004.html
Copyright © 2020-2023  润新知