public static class AutoscalingPolicy.Builder extends Object
Modifier and Type | Method and Description |
---|---|
AutoscalingPolicy.Builder |
addAllCustomMetricUtilizations(List<AutoscalingPolicyCustomMetricUtilization> customMetricUtilizations)
Configuration parameters of autoscaling based on a custom metric.
|
AutoscalingPolicy.Builder |
addCustomMetricUtilizations(AutoscalingPolicyCustomMetricUtilization customMetricUtilizations)
Configuration parameters of autoscaling based on a custom metric.
|
AutoscalingPolicy |
build() |
AutoscalingPolicy.Builder |
clone() |
Integer |
getCoolDownPeriodSec()
The number of seconds that the autoscaler should wait before it starts collecting information
from a new instance.
|
AutoscalingPolicyCpuUtilization |
getCpuUtilization()
Defines the CPU utilization policy that allows the autoscaler to scale based on the average
CPU utilization of a managed instance group.
|
List<AutoscalingPolicyCustomMetricUtilization> |
getCustomMetricUtilizationsList()
Configuration parameters of autoscaling based on a custom metric.
|
AutoscalingPolicyLoadBalancingUtilization |
getLoadBalancingUtilization()
Configuration parameters of autoscaling based on load balancer.
|
Integer |
getMaxNumReplicas()
The maximum number of instances that the autoscaler can scale up to.
|
Integer |
getMinNumReplicas()
The minimum number of replicas that the autoscaler can scale down to.
|
AutoscalingPolicy.Builder |
mergeFrom(AutoscalingPolicy other) |
AutoscalingPolicy.Builder |
setCoolDownPeriodSec(Integer coolDownPeriodSec)
The number of seconds that the autoscaler should wait before it starts collecting information
from a new instance.
|
AutoscalingPolicy.Builder |
setCpuUtilization(AutoscalingPolicyCpuUtilization cpuUtilization)
Defines the CPU utilization policy that allows the autoscaler to scale based on the average
CPU utilization of a managed instance group.
|
AutoscalingPolicy.Builder |
setLoadBalancingUtilization(AutoscalingPolicyLoadBalancingUtilization loadBalancingUtilization)
Configuration parameters of autoscaling based on load balancer.
|
AutoscalingPolicy.Builder |
setMaxNumReplicas(Integer maxNumReplicas)
The maximum number of instances that the autoscaler can scale up to.
|
AutoscalingPolicy.Builder |
setMinNumReplicas(Integer minNumReplicas)
The minimum number of replicas that the autoscaler can scale down to.
|
public AutoscalingPolicy.Builder mergeFrom(AutoscalingPolicy other)
public Integer getCoolDownPeriodSec()
Virtual machine initialization times might vary because of numerous factors. We recommend that you test how long an instance may take to initialize. To do this, create an instance and time the startup process.
public AutoscalingPolicy.Builder setCoolDownPeriodSec(Integer coolDownPeriodSec)
Virtual machine initialization times might vary because of numerous factors. We recommend that you test how long an instance may take to initialize. To do this, create an instance and time the startup process.
public AutoscalingPolicyCpuUtilization getCpuUtilization()
public AutoscalingPolicy.Builder setCpuUtilization(AutoscalingPolicyCpuUtilization cpuUtilization)
public List<AutoscalingPolicyCustomMetricUtilization> getCustomMetricUtilizationsList()
public AutoscalingPolicy.Builder addAllCustomMetricUtilizations(List<AutoscalingPolicyCustomMetricUtilization> customMetricUtilizations)
public AutoscalingPolicy.Builder addCustomMetricUtilizations(AutoscalingPolicyCustomMetricUtilization customMetricUtilizations)
public AutoscalingPolicyLoadBalancingUtilization getLoadBalancingUtilization()
public AutoscalingPolicy.Builder setLoadBalancingUtilization(AutoscalingPolicyLoadBalancingUtilization loadBalancingUtilization)
public Integer getMaxNumReplicas()
public AutoscalingPolicy.Builder setMaxNumReplicas(Integer maxNumReplicas)
public Integer getMinNumReplicas()
public AutoscalingPolicy.Builder setMinNumReplicas(Integer minNumReplicas)
public AutoscalingPolicy build()
public AutoscalingPolicy.Builder clone()
Copyright © 2019 Google LLC. All rights reserved.