LivenessProbeRequirements 类

定义 Webservice 部署的运行情况探测时间要求。

LivenessProbeRequirements 配置值在部署或更新 Webervice 时指定。 例如,使用 AksWebservice 类的 deploy_configurationupdate 方法,或 AksEndpoint 类的 create_versiondeploy_configurationupdate_version 方法。

初始化容器资源要求。

继承
builtins.object
LivenessProbeRequirements

构造函数

LivenessProbeRequirements(period_seconds, initial_delay_seconds, timeout_seconds, success_threshold, failure_threshold)

参数

period_seconds
int
必需

执行运行情况探测的频率(秒)。 默认值为 10 秒。 最小值为 1。

initial_delay_seconds
int
必需

启动容器后,启动运行情况探测前的秒数。

timeout_seconds
int
必需

运行情况探测超时前等待的秒数。默认值为 1 秒。 最小值为 1。

failure_threshold
int
必需

当 Pod 启动而运行情况探测失败时,Kubernetes 将尝试 failureThreshold 次才会放弃。 默认值为 3。 最小值为 1。

success_threshold
int
必需

失败后,运行情况探测被视为成功的最小连续成功次数。 默认值为 1。 最小值为 1。

period_seconds
int
必需

执行运行情况探测的频率(秒)。 默认值为 10 秒。 最小值为 1。

initial_delay_seconds
int
必需

启动容器后,启动运行情况探测前的秒数。

timeout_seconds
int
必需

运行情况探测超时前等待的秒数。默认值为 1 秒。 最小值为 1。

failure_threshold
int
必需

当 Pod 启动而运行情况探测失败时,Kubernetes 将尝试 failureThreshold 次才会放弃。 默认值为 3。 最小值为 1。

success_threshold
int
必需

失败后,运行情况探测被视为成功的最小连续成功次数。 默认值为 1。 最小值为 1。

变量

period_seconds
int

执行运行情况探测的频率(秒)。 默认值为 10 秒。 最小值为 1。

initial_delay_seconds
int

启动容器后,启动运行情况探测前的秒数。

timeout_seconds
int

运行情况探测超时前等待的秒数。默认值为 1 秒。 最小值为 1。

failure_threshold
int

当 Pod 启动而运行情况探测失败时,Kubernetes 将尝试 failureThreshold 次才会放弃。 默认值为 3。 最小值为 1。

success_threshold
int

失败后,运行情况探测被视为成功的最小连续成功次数。 默认值为 1。 最小值为 1。

方法

deserialize

将 JSON 对象转换为 LivenessProbeRequirements 对象。

serialize

将此 LivenessProbeRequirements 对象转换为 JSON 序列化字典。

deserialize

将 JSON 对象转换为 LivenessProbeRequirements 对象。

static deserialize(payload_obj)

参数

payload_obj
dict
必需

要转换为 LivenessProbeRequirements 对象的 JSON 对象。

返回

所提供的 JSON 对象的 LivenessProbeRequirements 表示形式。

返回类型

serialize

将此 LivenessProbeRequirements 对象转换为 JSON 序列化字典。

serialize()

返回

此 LivenessProbeRequirements 对象的 JSON 表示形式。

返回类型