diff options
author | Elijah DeLee <kdelee@redhat.com> | 2022-02-15 20:08:24 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-02-15 20:08:24 +0100 |
commit | 799968460d4794bcd9959f57a2b97846b9a00bb7 (patch) | |
tree | 3b5de9a320cff8551c7ac62bf1b12496d4a207aa /.github | |
parent | Merge pull request #11571 from amolgautam25/tasks-refactor-2 (diff) | |
download | awx-799968460d4794bcd9959f57a2b97846b9a00bb7.tar.xz awx-799968460d4794bcd9959f57a2b97846b9a00bb7.zip |
Fixup conversion of memory and cpu settings to support k8s resource request format (#11725)20.0.0
fix memory and cpu settings to suport k8s resource request format
* fix conversion of memory setting to bytes
This setting has not been getting set by default, and needed some fixing
up to be compatible with setting the memory in the same way as we set it
in the operator, as well as with other changes from last year which
assume that ansible runner is returning memory in bytes.
This way we can start setting this setting in the operator, and get a
more accurate reflection of how much memory is available to the control
pod in k8s.
On platforms where services are all sharing memory, we deduct a
penalty from the memory available. On k8s we don't need to do this
because the web, redis, and task containers each have memory
allocated to them.
* Support CPU setting expressed in units used by k8s
This setting has not been getting set by default, and needed some fixing
up to be compatible with setting the CPU resource request/limits in the
same way as we set it in the resource requests/limits.
This way we can start setting this setting in the
operator, and get a more accurate reflection of how much cpu is
available to the control pod in k8s.
Because cpu on k8s can be partial cores, migrate cpu field to decimal.
k8s does not allow granularity of less than 100m (equivalent to 0.1 cores), so only
store up to 1 decimal place.
fix analytics to deal with decimal cpu
need to use DjangoJSONEncoder when Decimal fields in data passed to
json.dumps
Diffstat (limited to '.github')
0 files changed, 0 insertions, 0 deletions