Expose power sync parameters
A busy environment is likely to tune these parameters, let's expose them. Change-Id: Ide6de7f7a147e15b2941706f282455baa9d8f671
This commit is contained in:
parent
0d0fbabd6a
commit
5310a06d46
@ -136,6 +136,16 @@
|
||||
# so that the baremetal node is in the desired new power state.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*sync_power_state_interval*]
|
||||
# (optional) Interval between syncing the node power state to the database,
|
||||
# in seconds.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*power_state_sync_max_retries*]
|
||||
# (optional) The number of times Ironic should try syncing the hardware node
|
||||
# power state with the node power state in the database.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# DEPRECATED PARAMETERS
|
||||
#
|
||||
# [*enabled_drivers*]
|
||||
@ -167,6 +177,8 @@ class ironic::conductor (
|
||||
$provisioning_network_name = undef,
|
||||
$rescuing_network_name = undef,
|
||||
$power_state_change_timeout = $::os_service_default,
|
||||
$sync_power_state_interval = $::os_service_default,
|
||||
$power_state_sync_max_retries = $::os_service_default,
|
||||
$enabled_drivers = undef,
|
||||
) {
|
||||
|
||||
@ -248,6 +260,8 @@ class ironic::conductor (
|
||||
'deploy/default_boot_option': value => $default_boot_option;
|
||||
'neutron/port_setup_delay': value => $port_setup_delay;
|
||||
'conductor/power_state_change_timeout': value => $power_state_change_timeout;
|
||||
'conductor/sync_power_state_interval': value => $sync_power_state_interval;
|
||||
'conductor/power_state_sync_max_retries': value => $power_state_sync_max_retries;
|
||||
}
|
||||
|
||||
if $cleaning_network_name {
|
||||
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
features:
|
||||
- |
|
||||
Expose the ``sync_power_state_interval`` and
|
||||
``power_state_sync_max_retries`` parametes in ``ironic::conductor``.
|
@ -80,6 +80,8 @@ describe 'ironic::conductor' do
|
||||
is_expected.to contain_ironic_config('deploy/default_boot_option').with(:value => '<SERVICE DEFAULT>')
|
||||
is_expected.to contain_ironic_config('neutron/port_setup_delay').with(:value => '<SERVICE DEFAULT>')
|
||||
is_expected.to contain_ironic_config('conductor/power_state_change_timeout').with(:value => '<SERVICE DEFAULT>')
|
||||
is_expected.to contain_ironic_config('conductor/sync_power_state_interval').with(:value => '<SERVICE DEFAULT>')
|
||||
is_expected.to contain_ironic_config('conductor/power_state_sync_max_retries').with(:value => '<SERVICE DEFAULT>')
|
||||
end
|
||||
|
||||
context 'when overriding parameters' do
|
||||
@ -100,7 +102,9 @@ describe 'ironic::conductor' do
|
||||
:configdrive_swift_container => 'cont',
|
||||
:default_boot_option => 'local',
|
||||
:port_setup_delay => '15',
|
||||
:power_state_change_timeout => '300'
|
||||
:power_state_change_timeout => '300',
|
||||
:sync_power_state_interval => 120,
|
||||
:power_state_sync_max_retries => 5,
|
||||
)
|
||||
end
|
||||
it 'should replace default parameter with new value' do
|
||||
@ -121,6 +125,8 @@ describe 'ironic::conductor' do
|
||||
is_expected.to contain_ironic_config('deploy/default_boot_option').with_value(p[:default_boot_option])
|
||||
is_expected.to contain_ironic_config('neutron/port_setup_delay').with_value(p[:port_setup_delay])
|
||||
is_expected.to contain_ironic_config('conductor/power_state_change_timeout').with_value(p[:power_state_change_timeout])
|
||||
is_expected.to contain_ironic_config('conductor/sync_power_state_interval').with_value(p[:sync_power_state_interval])
|
||||
is_expected.to contain_ironic_config('conductor/power_state_sync_max_retries').with_value(p[:power_state_sync_max_retries])
|
||||
end
|
||||
end
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user