Update the Kubernetes autoscaling API to v2 (#2722) (#2842)

* Update the Kubernetes autoscaling API to v2 (#2722)
  - k8s.io/api/autoscaling/v2
* generate all files
* fix missing v2beta ref

---------

Signed-off-by: Lunik <lunik@tiwabbit.fr>
This commit is contained in:
Guillaume MARTINEZ
2023-10-11 11:04:45 +05:30
committed by GitHub
parent b43b31884a
commit 3762ff80f2
10 changed files with 52 additions and 51 deletions
@@ -116,7 +116,7 @@ func (res KubernetesObjectDumper) Dump(ctx context.Context, dumpDir string) {
}
case KubernetesHPA:
objs, err := res.client.AutoscalingV2beta2().HorizontalPodAutoscalers(metav1.NamespaceAll).List(ctx, metav1.ListOptions{LabelSelector: res.selector})
objs, err := res.client.AutoscalingV2().HorizontalPodAutoscalers(metav1.NamespaceAll).List(ctx, metav1.ListOptions{LabelSelector: res.selector})
if err != nil {
console.Error(fmt.Sprintf("Error getting %v list with selector %v: %v", res.objType, res.selector, err))
return