open-nomad/website/pages/docs/autoscaling/internals/checks.mdx
James Rasell 9cc5540926
docs: migration of Nomad Autoscaler docs with cluster updates.
Co-authored-by: Chris Baker <1675087+cgbaker@users.noreply.github.com>
2020-07-01 13:03:49 +02:00

28 lines
1,005 B
Plaintext

---
layout: docs
page_title: Checks
sidebar_title: Checks
description: Learn about how the Autoscaler deals with policy checks.
---
# Nomad Autoscaler Check Calculations
A scaling policy can include several checks all of which produce a scaling
suggesting. The checks are executed at the same time during a policy evaluation
and the results can conflict with each other. In a scenario like this, the
autoscaler iterates the results the chooses the safest result which results in
retaining the most capacity of the resource.
In a scenario where two checks return different desired directions, the following
logic is applied.
- `ScaleOut and ScaleIn => ScaleOut`
- `ScaleOut and ScaleNone => ScaleOut`
- `ScaleIn and ScaleNone => ScaleNone`
In situations where the two same actions are suggested, but with different counts the
following logic is applied, where the count is the absolute desired value.
- `ScaleOut(10) and ScaleOut(9) => ScaleOut(10)`
- `ScaleIn(3) and ScaleIn(4) => ScaleIn(4)`