filter_scheduler: Add support for new multiplier options
This introduces support for the two new multiplier options which were added to nova during Bobcat cycle. Depends-on: https://review.opendev.org/880231 Depneds-on: https://review.opendev.org/886232 Change-Id: I58eb4241dd04cf8e932c0f84d9575b3ee6169876
This commit is contained in:
parent
a5b68f7319
commit
f1b20af309
@ -79,8 +79,16 @@
|
||||
# (optional) Multiplier used for weighing hosts during a cross-cell move
|
||||
# Defaults to $facts['os_service_default']
|
||||
#
|
||||
# [*num_instances_weight_multiplier*]
|
||||
# (optional) Number of instances weight multiplier ratio.
|
||||
# Defaults to $facts['os_service_default']
|
||||
#
|
||||
# [*hypervisor_version_weight_multiplier*]
|
||||
# (optional) Hypervisor Version weight multiplier ratio.
|
||||
# Defaults to $facts['os_service_default']
|
||||
#
|
||||
# [*shuffle_best_same_weighed_hosts*]
|
||||
# (Optional) Enabled spreading the instances between hosts with the same
|
||||
# (optional) Enabled spreading the instances between hosts with the same
|
||||
# best weight
|
||||
# Defaults to $facts['os_service_default']
|
||||
#
|
||||
@ -114,6 +122,8 @@ class nova::scheduler::filter (
|
||||
$soft_anti_affinity_weight_multiplier = $facts['os_service_default'],
|
||||
$build_failure_weight_multiplier = $facts['os_service_default'],
|
||||
$cross_cell_move_weight_multiplier = $facts['os_service_default'],
|
||||
$num_instances_weight_multiplier = $facts['os_service_default'],
|
||||
$hypervisor_version_weight_multiplier = $facts['os_service_default'],
|
||||
$shuffle_best_same_weighed_hosts = $facts['os_service_default'],
|
||||
$restrict_isolated_hosts_to_isolated_images = $facts['os_service_default'],
|
||||
$aggregate_image_properties_isolation_namespace = $facts['os_service_default'],
|
||||
@ -171,6 +181,10 @@ class nova::scheduler::filter (
|
||||
value => $build_failure_weight_multiplier;
|
||||
'filter_scheduler/cross_cell_move_weight_multiplier':
|
||||
value => $cross_cell_move_weight_multiplier;
|
||||
'filter_scheduler/num_instances_weight_multiplier':
|
||||
value => $num_instances_weight_multiplier;
|
||||
'filter_scheduler/hypervisor_version_weight_multiplier':
|
||||
value => $hypervisor_version_weight_multiplier;
|
||||
'filter_scheduler/shuffle_best_same_weighed_hosts':
|
||||
value => $shuffle_best_same_weighed_hosts;
|
||||
'filter_scheduler/restrict_isolated_hosts_to_isolated_images':
|
||||
|
@ -0,0 +1,8 @@
|
||||
---
|
||||
features:
|
||||
- |
|
||||
The ``nova::scheduler::filter`` class now supports the following two
|
||||
new parameters.
|
||||
|
||||
- ``hypervisor_version_weight_multiplier``
|
||||
- ``num_instances_weight_multiplier``
|
@ -26,6 +26,8 @@ describe 'nova::scheduler::filter' do
|
||||
it { is_expected.to contain_nova_config('filter_scheduler/soft_anti_affinity_weight_multiplier').with_value('<SERVICE DEFAULT>') }
|
||||
it { is_expected.to contain_nova_config('filter_scheduler/build_failure_weight_multiplier').with_value('<SERVICE DEFAULT>') }
|
||||
it { is_expected.to contain_nova_config('filter_scheduler/cross_cell_move_weight_multiplier').with_value('<SERVICE DEFAULT>') }
|
||||
it { is_expected.to contain_nova_config('filter_scheduler/hypervisor_version_weight_multiplier').with_value('<SERVICE DEFAULT>') }
|
||||
it { is_expected.to contain_nova_config('filter_scheduler/num_instances_weight_multiplier').with_value('<SERVICE DEFAULT>') }
|
||||
it { is_expected.to contain_nova_config('filter_scheduler/shuffle_best_same_weighed_hosts').with_value('<SERVICE DEFAULT>') }
|
||||
it { is_expected.to contain_nova_config('filter_scheduler/restrict_isolated_hosts_to_isolated_images').with_value('<SERVICE DEFAULT>') }
|
||||
it { is_expected.to contain_nova_config('filter_scheduler/aggregate_image_properties_isolation_namespace').with_value('<SERVICE DEFAULT>') }
|
||||
@ -56,6 +58,8 @@ describe 'nova::scheduler::filter' do
|
||||
:soft_anti_affinity_weight_multiplier => 60,
|
||||
:build_failure_weight_multiplier => 100,
|
||||
:cross_cell_move_weight_multiplier => 1000,
|
||||
:hypervisor_version_weight_multiplier => 70,
|
||||
:num_instances_weight_multiplier => 0,
|
||||
:shuffle_best_same_weighed_hosts => true,
|
||||
}
|
||||
end
|
||||
@ -72,6 +76,8 @@ describe 'nova::scheduler::filter' do
|
||||
it { is_expected.to contain_nova_config('filter_scheduler/soft_anti_affinity_weight_multiplier').with_value(60) }
|
||||
it { is_expected.to contain_nova_config('filter_scheduler/build_failure_weight_multiplier').with_value(100) }
|
||||
it { is_expected.to contain_nova_config('filter_scheduler/cross_cell_move_weight_multiplier').with_value(1000) }
|
||||
it { is_expected.to contain_nova_config('filter_scheduler/hypervisor_version_weight_multiplier').with_value(70) }
|
||||
it { is_expected.to contain_nova_config('filter_scheduler/num_instances_weight_multiplier').with_value(0) }
|
||||
it { is_expected.to contain_nova_config('filter_scheduler/shuffle_best_same_weighed_hosts').with_value(true) }
|
||||
it { is_expected.to contain_nova_config('filter_scheduler/isolated_images').with_value('ubuntu1,centos2') }
|
||||
it { is_expected.to contain_nova_config('filter_scheduler/isolated_hosts').with_value('192.168.1.2,192.168.1.3') }
|
||||
|
Loading…
x
Reference in New Issue
Block a user