app-autoscaler-release
app-autoscaler-release copied to clipboard
feat(scalingengine): Support app annotation to disable autoscaling
Background
During DevOps tasks such as deployments or periods where manual scaling is required (e.g., in an outage situation) a simple and quick way to disable autoscaling might be helpful that does not involve editing or deleting the autoscaling policy.
Details
This PR introduces an annotation
app-autoscaler.cloudfoundry.org/disable-autoscaling
.
If it is set on an app the app-autoscaler will not
scale it, even if a scaling policy is active.
Instead an event is written to scaling history,
referencing the annotation.
The annotation value should be used to document the reason why this annotation is set and will be reflected in the scaling history.
The main commit is https://github.com/cloudfoundry/app-autoscaler-release/pull/2824/commits/84b078fd2d82e7e57ce684f244d4b9349979724c - the other changes are unrelated and could be split out to their own PRs if necessary.