你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn。
DeploymentSettings 类
- java.
lang. Object - com.
azure. resourcemanager. appplatform. models. DeploymentSettings
- com.
public final class DeploymentSettings
部署设置有效负载。
构造函数摘要
构造函数 | 说明 | |
---|---|---|
DeploymentSettings() |
方法摘要
方法继承自 java.lang.Object
构造函数详细信息
DeploymentSettings
public DeploymentSettings()
方法详细信息
addonConfigs
public Map
获取 addonConfigs 属性:加载项集合。
Returns:
containerProbeSettings
public ContainerProbeSettings containerProbeSettings()
获取 containerProbeSettings 属性:容器运行情况和就绪情况探测设置。
Returns:
environmentVariables
public Map
获取 environmentVariables 属性:环境变量的集合。
Returns:
livenessProbe
public Probe livenessProbe()
获取 livenessProbe 属性:应用实例运行情况的定期探测。 如果探测失败,将重启应用实例。 详细信息: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle\#container-probes。
Returns:
readinessProbe
public Probe readinessProbe()
获取 readinessProbe 属性:应用实例服务就绪情况的定期探测。 如果探测失败,将从服务终结点中删除应用实例。 详细信息: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle\#container-probes。
Returns:
resourceRequests
public ResourceRequests resourceRequests()
获取 resourceRequests 属性:所需 CPU 和内存的请求资源数量。 建议使用此字段来表示所需的 CPU 和内存,旧字段 cpu 和 memoryInGB 稍后将弃用。
Returns:
startupProbe
public Probe startupProbe()
获取 startupProbe 属性:StartupProbe 指示应用实例已成功初始化。 如果指定,则在成功完成之前,不会执行其他探测。 如果此探测失败,Pod 将重启,就像 livenessProbe 失败一样。 与在稳定状态操作期间相比,这可用于在应用实例生命周期开始时提供不同的探测参数,其中加载数据或预热缓存可能需要很长时间。 这无法更新。 详细信息: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle\#container-probes。
Returns:
terminationGracePeriodSeconds
public Integer terminationGracePeriodSeconds()
获取 terminationGracePeriodSeconds 属性:应用实例正常终止所需的可选持续时间(以秒为单位)。 删除请求中可能会减少。 值必须是非负整数。 值 0 指示通过终止信号立即停止, (没有机会关闭) 。 如果此值为 nil,则将改用默认宽限期。 宽限期是向应用实例中运行的进程发送终止信号后的持续时间(以秒为单位)以及进程被强行停止并发出终止信号的时间。 请将此值设置为大于你的进程的预期清理时间。 默认为 90 秒。
Returns:
validate
public void validate()
验证 实例。
withAddonConfigs
public DeploymentSettings withAddonConfigs(Map
设置 addonConfigs 属性:加载项集合。
Parameters:
Returns:
withContainerProbeSettings
public DeploymentSettings withContainerProbeSettings(ContainerProbeSettings containerProbeSettings)
设置 containerProbeSettings 属性:容器运行情况和就绪情况探测设置。
Parameters:
Returns:
withEnvironmentVariables
public DeploymentSettings withEnvironmentVariables(Map
设置 environmentVariables 属性:环境变量的集合。
Parameters:
Returns:
withLivenessProbe
public DeploymentSettings withLivenessProbe(Probe livenessProbe)
设置 livenessProbe 属性:应用实例运行情况的定期探测。 如果探测失败,将重启应用实例。 详细信息: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle\#container-probes。
Parameters:
Returns:
withReadinessProbe
public DeploymentSettings withReadinessProbe(Probe readinessProbe)
设置 readinessProbe 属性:应用实例服务就绪情况的定期探测。 如果探测失败,将从服务终结点中删除应用实例。 详细信息: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle\#container-probes。
Parameters:
Returns:
withResourceRequests
public DeploymentSettings withResourceRequests(ResourceRequests resourceRequests)
设置 resourceRequests 属性:所需 CPU 和内存的请求资源数量。 建议使用此字段来表示所需的 CPU 和内存,旧字段 cpu 和 memoryInGB 稍后将弃用。
Parameters:
Returns:
withStartupProbe
public DeploymentSettings withStartupProbe(Probe startupProbe)
设置 startupProbe 属性:StartupProbe 指示应用实例已成功初始化。 如果指定,则在成功完成之前不会执行其他探测。 如果此探测失败,Pod 将重启,就像 livenessProbe 失败一样。 这可用于在应用实例生命周期开始时提供不同的探测参数,这可能需要很长时间才能加载数据或预热缓存,而不是在稳定状态操作期间。 这无法更新。 详细信息: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle\#container-probes。
Parameters:
Returns:
withTerminationGracePeriodSeconds
public DeploymentSettings withTerminationGracePeriodSeconds(Integer terminationGracePeriodSeconds)
设置 terminateGracePeriodSeconds 属性:应用实例需要正常终止的可选持续时间(以秒为单位)。 删除请求中可能会减少。 值必须是非负整数。 值零表示通过终止信号立即停止, (没有机会关闭) 。 如果此值为 nil,则将改用默认宽限期。 宽限期是向应用实例中运行的进程发送终止信号后的持续时间(以秒为单位)以及进程被强行停止并发出终止信号的时间。 请将此值设置为大于你的进程的预期清理时间。 默认为 90 秒。
Parameters:
Returns: