Skip to content

Commit 73597ee

Browse files
Arjun Naikarjunrn
authored andcommitted
Updated Scaling Behavior KEP to reflect implementation
Signed-off-by: Arjun Naik <[email protected]>
1 parent 9d4deb4 commit 73597ee

File tree

1 file changed

+12
-14
lines changed
  • keps/sig-autoscaling/853-configurable-hpa-scale-velocity

1 file changed

+12
-14
lines changed

keps/sig-autoscaling/853-configurable-hpa-scale-velocity/README.md

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -84,20 +84,20 @@ To customize the scaling behavior we should add a `behavior` object with the fol
8484
- `scaleUp` specifies the rules which are used to control scaling behavior while scaling up.
8585
- `stabilizationWindowSeconds` - this value indicates the amount of time the HPA controller should consider
8686
previous recommendations to prevent flapping of the number of replicas.
87-
- `selectPolicy` can be `min` or `max` and specifies which value from the policies should be selected. The `max` value is used by default.
87+
- `selectPolicy` can be `Min`, `Max` or `Disabled` and specifies which value from the policies should be selected. The `Max` value is used by default.
8888
- `policies` a list of policies which regulate the amount of scaling. Each item has the following fields
89-
- `type` can have the value `pods` or `percent` which indicates the allowed changed in terms of absolute number of pods or percentage of current replicas.
89+
- `type` can have the value `Pods` or `Percent` which indicates the allowed changed in terms of absolute number of pods or percentage of current replicas.
9090
- `periodSeconds` the amount of time in seconds for which the rule should hold true.
9191
- `value` the value for the policy
9292
- `scaleDown` similar to the `scaleUp` but specifies the rules for scaling down.
9393

9494
A user will specify the parameters for the HPA, thus controlling the HPA logic.
9595

96-
The `selectPolicy` field indicates which policy should be applied. By default the `max` policy is chosen or in other words while scaling up the highest
96+
The `selectPolicy` field indicates which policy should be applied. By default the `Max` policy is chosen or in other words while scaling up the highest
9797
possible number of replicas is used and while scaling down the lowest possible number of replicas is chosen.
9898

9999
If the user does not specify `policies` for either `scaleUp` or `scaleDown` then default value for that policy is used
100-
(see the [Default Values] [] section below). Setting the `value` to `0` for `scaleUp` or `scaleDown` disables scaling in that direction.
100+
(see the [Default Values] [] section below).
101101

102102
[Default Values]: #default-values
103103
[Stabilization Window]: #stabilization-window
@@ -114,7 +114,7 @@ Create an HPA with the following configuration:
114114
behavior:
115115
scaleUp:
116116
policies:
117-
- type: percent
117+
- type: Percent
118118
value: 900%
119119
```
120120
@@ -142,11 +142,11 @@ Create an HPA with the following behavior:
142142
behavior:
143143
scaleUp:
144144
policies:
145-
- type: percent
145+
- type: Percent
146146
value: 900%
147147
scaleDown:
148148
policies:
149-
- type: pods
149+
- type: Pods
150150
value: 1
151151
periodSeconds: 600 # (i.e., scale down one pod every 10 min)
152152
```
@@ -165,7 +165,7 @@ Create an HPA with the following behavior:
165165
behavior:
166166
scaleUp:
167167
policies:
168-
- type: pods
168+
- type: Pods
169169
value: 1
170170
```
171171

@@ -186,9 +186,7 @@ Create an HPA with the following constraints:
186186
```yaml
187187
behavior:
188188
scaleDown:
189-
policies:
190-
- type: pods
191-
value: 0
189+
selectPolicy: Disabled
192190
```
193191

194192
The cluster will scale up as usual (default values), but will never scale down.
@@ -359,16 +357,16 @@ For smooth transition it makes sense to set the following default values:
359357
- `behavior.scaleUp.stabilizationWindowSeconds = 0`, do not gather recommendations, instantly scale up to the calculated number of replicas
360358
- `behavior.scaleUp.policies` has the following policies
361359
- Percentage policy
362-
- `policy = percent`
360+
- `policy = Percent`
363361
- `periodSeconds = 60`, one minute period for scaleUp
364362
- `value = 100` which means the number of replicas can be doubled every minute.
365363
- Pod policy
366-
- `policy = pods`
364+
- `policy = Pods`
367365
- `periodSeconds = 60`, one minute period for scaleUp
368366
- `value = 4` which means the 4 replicas can be added every minute.
369367
- `behavior.scaleDown.policies` has the following policies
370368
- Percentage Policy
371-
- `policy = percent`
369+
- `policy = Percent`
372370
- `periodSeconds = 60` one minute period for scaleDown
373371
- `value = 100` which means all the replicas can be scaled down in one minute.
374372

0 commit comments

Comments
 (0)