Deprecate support for [scheduler] periodic_task_interval
... because the parameter was removed from nova[1]. [1] 9d53f366ff8c9a29c4ddbf0fa27febbce7442fc9 Change-Id: Ie2e2c40a37c5d206ef483f48fac04a027f793b4b
This commit is contained in:
parent
0a3ab851a7
commit
3375efcfd4
|
@ -24,12 +24,6 @@
|
|||
# (optional) Maximum number of attempts to schedule an instance
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*periodic_task_interval*]
|
||||
# (Optional) This value controls how often (in seconds) to run periodic tasks
|
||||
# in the scheduler. The specific tasks that are run for each period are
|
||||
# determined by the particular scheduler being used.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*discover_hosts_in_cells_interval*]
|
||||
# (Optional) This value controls how often (in seconds) the scheduler should
|
||||
# attempt to discover new hosts that have been added to cells.
|
||||
|
@ -79,13 +73,20 @@
|
|||
# compute hosts affined to routed network segment aggregates.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# DEPRECATED PARAMETERS
|
||||
#
|
||||
# [*periodic_task_interval*]
|
||||
# (Optional) This value controls how often (in seconds) to run periodic tasks
|
||||
# in the scheduler. The specific tasks that are run for each period are
|
||||
# determined by the particular scheduler being used.
|
||||
# Defaults to undef
|
||||
#
|
||||
class nova::scheduler(
|
||||
$enabled = true,
|
||||
$manage_service = true,
|
||||
$ensure_package = 'present',
|
||||
$workers = $::os_workers,
|
||||
$max_attempts = $::os_service_default,
|
||||
$periodic_task_interval = $::os_service_default,
|
||||
$discover_hosts_in_cells_interval = $::os_service_default,
|
||||
$query_placement_for_image_type_support = $::os_service_default,
|
||||
$limit_tenants_to_placement_aggregate = $::os_service_default,
|
||||
|
@ -94,6 +95,8 @@ class nova::scheduler(
|
|||
$enable_isolated_aggregate_filtering = $::os_service_default,
|
||||
$query_placement_for_availability_zone = $::os_service_default,
|
||||
$query_placement_for_routed_network_aggregates = $::os_service_default,
|
||||
# DEPRECATED PARAMETERS
|
||||
$periodic_task_interval = undef,
|
||||
) {
|
||||
|
||||
include nova::deps
|
||||
|
@ -101,6 +104,10 @@ class nova::scheduler(
|
|||
include nova::params
|
||||
include nova::availability_zone
|
||||
|
||||
if $periodic_task_interval != undef {
|
||||
warning('The periodic_task_interval parameter is depreated and has no effect')
|
||||
}
|
||||
|
||||
nova::generic_service { 'scheduler':
|
||||
enabled => $enabled,
|
||||
manage_service => $manage_service,
|
||||
|
@ -112,7 +119,6 @@ class nova::scheduler(
|
|||
nova_config {
|
||||
'scheduler/workers': value => $workers;
|
||||
'scheduler/max_attempts': value => $max_attempts;
|
||||
'scheduler/periodic_task_interval': value => $periodic_task_interval;
|
||||
'scheduler/discover_hosts_in_cells_interval': value => $discover_hosts_in_cells_interval;
|
||||
'scheduler/query_placement_for_image_type_support': value => $query_placement_for_image_type_support;
|
||||
'scheduler/limit_tenants_to_placement_aggregate': value => $limit_tenants_to_placement_aggregate;
|
||||
|
@ -122,4 +128,8 @@ class nova::scheduler(
|
|||
'scheduler/query_placement_for_availability_zone': value => $query_placement_for_availability_zone;
|
||||
'scheduler/query_placement_for_routed_network_aggregates': value => $query_placement_for_routed_network_aggregates;
|
||||
}
|
||||
|
||||
nova_config {
|
||||
'scheduler/periodic_task_interval': ensure => absent;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
deprecations:
|
||||
- |
|
||||
The ``nova::scheduler::periodic_task_interval`` parameter has been
|
||||
deprecated and has no effect now.
|
|
@ -19,7 +19,7 @@ describe 'nova::scheduler' do
|
|||
|
||||
it { is_expected.to contain_nova_config('scheduler/workers').with_value(4) }
|
||||
it { is_expected.to contain_nova_config('scheduler/max_attempts').with_value('<SERVICE DEFAULT>') }
|
||||
it { is_expected.to contain_nova_config('scheduler/periodic_task_interval').with_value('<SERVICE DEFAULT>') }
|
||||
it { is_expected.to contain_nova_config('scheduler/periodic_task_interval').with_ensure('absent') }
|
||||
it { is_expected.to contain_nova_config('scheduler/discover_hosts_in_cells_interval').with_value('<SERVICE DEFAULT>') }
|
||||
it { is_expected.to contain_nova_config('scheduler/query_placement_for_image_type_support').with_value('<SERVICE DEFAULT>') }
|
||||
it { is_expected.to contain_nova_config('scheduler/limit_tenants_to_placement_aggregate').with_value('<SERVICE DEFAULT>') }
|
||||
|
@ -66,14 +66,6 @@ describe 'nova::scheduler' do
|
|||
it { is_expected.to contain_nova_config('scheduler/max_attempts').with_value(10) }
|
||||
end
|
||||
|
||||
context 'with periodic_task_interval' do
|
||||
let :params do
|
||||
{ :periodic_task_interval => 300 }
|
||||
end
|
||||
|
||||
it { is_expected.to contain_nova_config('scheduler/periodic_task_interval').with_value(300) }
|
||||
end
|
||||
|
||||
context 'with discover_hosts_in_cells_interval' do
|
||||
let :params do
|
||||
{ :discover_hosts_in_cells_interval => 15 }
|
||||
|
|
Loading…
Reference in New Issue