HorizontalPodAutoscalerSpecV1 Properties
Class Properties 4 members
Specifies the desired behavior of a Horizontal Pod Autoscaler in Kubernetes for the autoscaling/v1 version.
Specifies the maximum allowed number of replicas for the target resource managed by the HorizontalPodAutoscaler.
public int MaxReplicas { get; set; }Remarks
The MaxReplicas property defines an upper limit on the number of replicas that can be created for the specified workload. This ensures that the scaling process does not exceed operational constraints or resource limits, even if usage metrics surpass thresholds.
Gets or sets the minimum number of replicas that the HorizontalPodAutoscaler will maintain for the specified resource.
public int? MinReplicas { get; set; }Remarks
This property ensures that the targeted application maintains a guaranteed minimum level of scalability, preventing the number of replicas from falling below the specified value. Setting this value is optional and, if not set, the default value may rely on the Kubernetes configuration for the HorizontalPodAutoscaler.
Specifies the reference to the target object that the HorizontalPodAutoscaler is scaling.
public CrossVersionObjectReferenceV1 ScaleTargetRef { get; set; }Remarks
The ScaleTargetRef property is a reference to the Kubernetes resource that the HorizontalPodAutoscaler will monitor and scale. This reference includes essential details about the target resource, such as its name and API version, encapsulated in a CrossVersionObjectReferenceV1 object.
Gets or sets the target CPU utilization percentage for the horizontal pod autoscaler.
public int? TargetCPUUtilizationPercentage { get; set; }Remarks
This property defines the desired CPU utilization percentage threshold for the autoscaler to maintain. When the average CPU usage across the pods exceeds this value, additional replicas may be scaled up. Conversely, when the usage drops below this value, replicas may be scaled down.