taas: Deprecate vlan_range_start/end in agent side

These options can be now configured in neutron-server side, so these
implementations are no longer useful.

Related-Bug: #2081074
Change-Id: I69ab22792309164cc0aa30a1771fd6412ba9ef1c
This commit is contained in:
Takashi Kajinami 2024-09-18 23:42:06 +09:00
parent 134e26d17b
commit 87862a8ad1
3 changed files with 27 additions and 6 deletions

View File

@ -19,6 +19,8 @@
# [*package_ensure*]
# (optional) Ensure state for package. Defaults to 'present'.
#
# DEPRECATED PARAMETERS
#
# [*vlan_range_start*]
# (optional) Starting rantge of TAAS VLAN IDs.
# Defaults to $facts['os_service_default'].
@ -29,16 +31,27 @@
#
class neutron::agents::taas (
$package_ensure = present,
$vlan_range_start = $facts['os_service_default'],
$vlan_range_end = $facts['os_service_default'],
# DEPRECATED PARAMETERS
$vlan_range_start = undef,
$vlan_range_end = undef,
) {
include neutron::deps
include neutron::params
[
'vlan_range_start',
'vlan_range_end'
].each | $opt | {
if getvar($opt) {
warning("The ${opt} parameter has been deprecated and will be removed in a future release. \
Use the neutron::services::taas class parametes instead.")
}
}
neutron_plugin_ml2 {
'taas/vlan_range_start': value => $vlan_range_start;
'taas/vlan_range_end': value => $vlan_range_end;
'taas/vlan_range_start': value => pick($vlan_range_start, $facts['os_service_default']);
'taas/vlan_range_end': value => pick($vlan_range_end, $facts['os_service_default']);
}
ensure_packages( 'neutron-taas', {

View File

@ -6,3 +6,11 @@ features:
- ``vlan_range_start``
- ``vlan_range_end``
deprecations:
- |
The following parameters of the ``neutron::agents::taas`` class have been
deprecated.
- ``vlan_range_start``
- ``vlan_range_end``

View File

@ -13,7 +13,7 @@ describe 'neutron::agents::taas' do
context 'with defaults' do
it { should contain_class('neutron::params') }
it 'configures taas_plugin.ini' do
it 'configures ml2_plugin.conf' do
should contain_neutron_plugin_ml2('taas/vlan_range_start').with_value('<SERVICE DEFAULT>')
should contain_neutron_plugin_ml2('taas/vlan_range_end').with_value('<SERVICE DEFAULT>')
end
@ -35,7 +35,7 @@ describe 'neutron::agents::taas' do
}
end
it 'configures taas_plugin.ini' do
it 'configures ml2_plugin.conf' do
should contain_neutron_plugin_ml2('taas/vlan_range_start').with_value(1)
should contain_neutron_plugin_ml2('taas/vlan_range_end').with_value(100)
end