PAASTA-18383: Update V2Beta2 HPA api references to V2 for 1.26 #4007
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
As per https://kubernetes.io/docs/reference/using-api/deprecation-guide/#horizontalpodautoscaler-v126 the V2beta2 version of the HorizontalPodAutoscaler api is being deprecated in 1.26.
This updates as per recommendations to v2, and as all of our clusters are >1.23 they should support it.
Note that we did not use
targetAverageUtilization
that has been switched totarget.type=Utilization
+target.averageUtilization
, as we'd already used the latter in our code.This has been tested in paasta playground and infrastage and s_k_j was able to create/modify the appropriate HPA objects and autoscaling was successful.
Confirmed with audit logs that paasta was sending the request to
autoscaling/v2
rather thanautoscaling/v2beta2
with the change.