Merge "improve strategy doc"

This commit is contained in:
Zuul 2018-08-07 10:34:44 +00:00 committed by Gerrit Code Review
commit 0c41f20df2
2 changed files with 32 additions and 11 deletions

View File

@ -31,6 +31,8 @@ LOG = log.getLogger(__name__)
class SavingEnergy(base.SavingEnergyBaseStrategy): class SavingEnergy(base.SavingEnergyBaseStrategy):
"""Saving Energy Strategy """Saving Energy Strategy
*Description*
Saving Energy Strategy together with VM Workload Consolidation Strategy Saving Energy Strategy together with VM Workload Consolidation Strategy
can perform the Dynamic Power Management (DPM) functionality, which tries can perform the Dynamic Power Management (DPM) functionality, which tries
to save power by dynamically consolidating workloads even further during to save power by dynamically consolidating workloads even further during
@ -51,6 +53,8 @@ class SavingEnergy(base.SavingEnergyBaseStrategy):
the given number and there are spare unused nodes(in poweroff state), the given number and there are spare unused nodes(in poweroff state),
randomly select some nodes(unused,poweroff) and power on them. randomly select some nodes(unused,poweroff) and power on them.
*Requirements*
In this policy, in order to calculate the min_free_hosts_num, In this policy, in order to calculate the min_free_hosts_num,
users must provide two parameters: users must provide two parameters:
@ -64,6 +68,14 @@ class SavingEnergy(base.SavingEnergyBaseStrategy):
The nodes with VMs refer to those nodes with VMs running on it. The nodes with VMs refer to those nodes with VMs running on it.
Then choose the larger one as the final min_free_hosts_num. Then choose the larger one as the final min_free_hosts_num.
*Limitations*
* at least 2 physical compute hosts
*Spec URL*
http://specs.openstack.org/openstack/watcher-specs/specs/pike/implemented/energy-saving-strategy.html
""" """
def __init__(self, config, osc=None): def __init__(self, config, osc=None):
@ -113,16 +125,16 @@ class SavingEnergy(base.SavingEnergyBaseStrategy):
"properties": { "properties": {
"free_used_percent": { "free_used_percent": {
"description": ("a rational number, which describes the" "description": ("a rational number, which describes the"
"quotient of" " quotient of"
" min_free_hosts_num/nodes_with_VMs_num" " min_free_hosts_num/nodes_with_VMs_num"
"where nodes_with_VMs_num is the number" " where nodes_with_VMs_num is the number"
"of nodes with VMs"), " of nodes with VMs"),
"type": "number", "type": "number",
"default": 10.0 "default": 10.0
}, },
"min_free_hosts_num": { "min_free_hosts_num": {
"description": ("minimum number of hosts without VMs" "description": ("minimum number of hosts without VMs"
"but still powered on"), " but still powered on"),
"type": "number", "type": "number",
"default": 1 "default": 1
}, },

View File

@ -41,6 +41,15 @@ class StorageCapacityBalance(base.WorkloadStabilizationBaseStrategy):
* You must have at least 2 cinder volume pools to run * You must have at least 2 cinder volume pools to run
this strategy. this strategy.
*Limitations*
* Volume migration depends on the storage device.
It may take a long time.
*Spec URL*
http://specs.openstack.org/openstack/watcher-specs/specs/queens/implemented/storage-capacity-balance.html
""" """
def __init__(self, config, osc=None): def __init__(self, config, osc=None):