diff --git a/docs/api/index.html b/docs/api/index.html index 971760ef..98d14aee 100644 --- a/docs/api/index.html +++ b/docs/api/index.html @@ -550,32 +550,32 @@

AutoscalerSpec -behavior
+metrics
- -Kubernetes autoscaling/v2.HorizontalPodAutoscalerBehavior + +[]Kubernetes autoscaling/v2.MetricSpec (Optional) -

Behavior specifies the scaling behavior of the target in both Up and Down directions.

+

Metrics is meant to provide a customizable way to configure HPA metrics. +currently the only supported custom metrics is type=Pod. +Use TargetCPUUtilization or TargetMemoryUtilization instead if scaling on these common resource metrics.

-metrics
+behavior
- -[]Kubernetes autoscaling/v2.MetricSpec + +Kubernetes autoscaling/v2.HorizontalPodAutoscalerBehavior (Optional) -

Metrics is meant to provide a customizable way to configure HPA metrics. -currently the only supported custom metrics is type=Pod. -Use TargetCPUUtilization or TargetMemoryUtilization instead if scaling on these common resource metrics.

+

Behavior specifies the scaling behavior of the target in both Up and Down directions.

diff --git a/pkg/apis/planetscale/v2/vitesscell_types.go b/pkg/apis/planetscale/v2/vitesscell_types.go index 2548752b..f7e69e6a 100644 --- a/pkg/apis/planetscale/v2/vitesscell_types.go +++ b/pkg/apis/planetscale/v2/vitesscell_types.go @@ -132,16 +132,16 @@ type AutoscalerSpec struct { // +kubebuilder:validation:Minimum=0 MaxReplicas int32 `json:"maxReplicas,omitempty"` - // Behavior specifies the scaling behavior of the target in both Up and Down directions. - // +optional - Behavior *autoscalingv2.HorizontalPodAutoscalerBehavior `json:"behavior,omitempty"` - // Metrics is meant to provide a customizable way to configure HPA metrics. // currently the only supported custom metrics is type=Pod. // Use TargetCPUUtilization or TargetMemoryUtilization instead if scaling on these common resource metrics. // +listType=atomic // +optional Metrics []autoscalingv2.MetricSpec `json:"metrics,omitempty"` + + // Behavior specifies the scaling behavior of the target in both Up and Down directions. + // +optional + Behavior *autoscalingv2.HorizontalPodAutoscalerBehavior `json:"behavior,omitempty"` } // VitessCellGatewaySpec specifies the per-cell deployment parameters for vtgate. diff --git a/pkg/apis/planetscale/v2/zz_generated.deepcopy.go b/pkg/apis/planetscale/v2/zz_generated.deepcopy.go index ec109576..ace6b890 100644 --- a/pkg/apis/planetscale/v2/zz_generated.deepcopy.go +++ b/pkg/apis/planetscale/v2/zz_generated.deepcopy.go @@ -18,11 +18,6 @@ func (in *AutoscalerSpec) DeepCopyInto(out *AutoscalerSpec) { *out = new(int32) **out = **in } - if in.Behavior != nil { - in, out := &in.Behavior, &out.Behavior - *out = new(autoscalingv2.HorizontalPodAutoscalerBehavior) - (*in).DeepCopyInto(*out) - } if in.Metrics != nil { in, out := &in.Metrics, &out.Metrics *out = make([]autoscalingv2.MetricSpec, len(*in)) @@ -30,6 +25,11 @@ func (in *AutoscalerSpec) DeepCopyInto(out *AutoscalerSpec) { (*in)[i].DeepCopyInto(&(*out)[i]) } } + if in.Behavior != nil { + in, out := &in.Behavior, &out.Behavior + *out = new(autoscalingv2.HorizontalPodAutoscalerBehavior) + (*in).DeepCopyInto(*out) + } } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AutoscalerSpec.