2588af87c8
The ComputeNode object itself has a facade which provides the actual default values for cpu, disk and ram allocation ratios when the config option values are left at the default (0.0). When we initially create a ComputeNode in the ResourceTracker, the *_allocation_ratio values in the object are going to be unset, and then _copy_resources, called from _init_compute_node, will set the values to the config option values, again, defaulted to 0.0, but the ComputeNode object, after calling create() or save(), will change those *on the object* to the non-0.0 we actually know and love (16.0 for cpu, 1.5 for ram, and 1.0 for disk). During the update_available_resource periodic, we'll again go through _init_compute_node and _copy_resources in the ResourceTracker which will set the configured values (default of 0.0) onto the ComputeNode object, which makes the _resource_change method, called from _update, return True and trigger a ComputeNode.save() call from the _update method. At that point we're *persisting* the 0.0 allocation ratios in the database, even though ComputeNode.save will change them to their non-0.0 default values *on the object* because of the _from_db_object call at the end of ComputeNode.save. So even if the ComputeNode object allocation ratio values are the non-0.0 defaults, we'll *always* update the database on every periodic even if nothing else changed in inventory. This change modifies the _copy_resource method to only update the ComputeNode fields if the configured ratios are not the 0.0 default. Change-Id: I43a23a3290db0c835fed01b8d6a38962dc61adce Related-Bug: #1789654 |
||
---|---|---|
api-guide/source | ||
api-ref/source | ||
contrib | ||
devstack | ||
doc | ||
etc/nova | ||
gate | ||
nova | ||
placement-api-ref | ||
playbooks/legacy | ||
releasenotes | ||
tools | ||
.coveragerc | ||
.gitignore | ||
.gitreview | ||
.mailmap | ||
.stestr.conf | ||
.zuul.yaml | ||
CONTRIBUTING.rst | ||
HACKING.rst | ||
LICENSE | ||
MAINTAINERS | ||
README.rst | ||
babel.cfg | ||
bindep.txt | ||
lower-constraints.txt | ||
requirements.txt | ||
setup.cfg | ||
setup.py | ||
test-requirements.txt | ||
tox.ini |
README.rst
Team and repository tags
OpenStack Nova
OpenStack Nova provides a cloud computing fabric controller, supporting a wide variety of compute technologies, including: libvirt (KVM, Xen, LXC and more), Hyper-V, VMware, XenServer, OpenStack Ironic and PowerVM.
Use the following resources to learn more.
API
To learn how to use Nova's API, consult the documentation available online at:
For more information on OpenStack APIs, SDKs and CLIs in general, refer to:
Operators
To learn how to deploy and configure OpenStack Nova, consult the documentation available online at:
In the unfortunate event that bugs are discovered, they should be reported to the appropriate bug tracker. If you obtained the software from a 3rd party operating system vendor, it is often wise to use their own bug tracker for reporting problems. In all other cases use the master OpenStack bug tracker, available at:
Developers
For information on how to contribute to Nova, please see the contents of the CONTRIBUTING.rst.
Any new code must follow the development guidelines detailed in the HACKING.rst file, and pass all unit tests.
Further developer focused documentation is available at:
Other Information
During each Summit and Project Team Gathering, we agree on what the whole community wants to focus on for the upcoming release. The plans for nova can be found at: