-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
a377608
commit 2612922
Showing
19 changed files
with
2,111 additions
and
316 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
# Migration from v0.11.2 to v0.12.0 | ||
|
||
There are some minor breaking changes moving from Predictive Horizontal Pod Autoscaler `v0.11.2` to `v0.12.0` - this | ||
page will detail how you can migrate between versions and handle these breaking changes. | ||
|
||
This is split into two parts, for most users of the PHPA the only part that will apply is [Migrating Predictive | ||
Horizontal Pod Autoscaler definitions](#migrating-predictive-horizontal-pod-autoscaler-definitions), the section | ||
on [Go code dependencies](#migrating-go-code-dependencies) only applies if you have a Go project that directly depends | ||
on the Go modules exposed in this project. | ||
|
||
## Migrating Predictive Horizontal Pod Autoscaler definitions | ||
|
||
The Predictive Horizontal Pod Autoscaler no longer has the `downscaleStabilization` field, this has been replaced by | ||
the [`behavior` field](../../reference/configuration.md#behavior). | ||
|
||
To apply downscale stabilization you can now use this `behavior` field. | ||
|
||
For example: | ||
|
||
```yaml | ||
spec: | ||
scaleTargetRef: | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
name: php-apache | ||
minReplicas: 1 | ||
maxReplicas: 10 | ||
downscaleStabilization: 0 | ||
``` | ||
|
||
Would instead be: | ||
|
||
```yaml | ||
spec: | ||
scaleTargetRef: | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
name: php-apache | ||
minReplicas: 1 | ||
maxReplicas: 10 | ||
behavior: | ||
scaleDown: | ||
stabilizationWindowSeconds: 0 | ||
``` | ||
|
||
## Migrating Go code dependencies | ||
|
||
The Go code no longer uses the `autoscaling/v2beta2` types, instead using the `autoscaling/v2`. This affects these | ||
Go types: | ||
|
||
- `CrossVersionObjectReference` in the `scaleTargetRef` field. | ||
- `MetricSpec` in the `metrics` field. | ||
- `MetricStatus` in the `currentMetrics` field. | ||
|
||
To migrate these switch from importing `autoscaling/v2beta2` to importing `autoscaling/v2`. | ||
|
||
For example: | ||
|
||
```go | ||
import autoscalingv2 "k8s.io/api/autoscaling/v2beta2" | ||
``` | ||
|
||
Would instead be: | ||
|
||
```go | ||
import autoscalingv2 "k8s.io/api/autoscaling/v2" | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
Flask==1.0 | ||
Flask==2.2.2 |
Oops, something went wrong.