Deprecate ovsdb_interface
This was removed from Neutron in 2018 and
it now always defaults to native [1].
[1] cf37563c83
Change-Id: Iec0b1a897709a549026f75dd18ca1a627c9995aa
This commit is contained in:
parent
95f442bd61
commit
3568ccf3d7
@ -139,11 +139,6 @@
|
|||||||
# (optional) The vhost-user socket directory for OVS
|
# (optional) The vhost-user socket directory for OVS
|
||||||
# Defaults to $::os_service_default
|
# Defaults to $::os_service_default
|
||||||
#
|
#
|
||||||
# [*ovsdb_interface*]
|
|
||||||
# (optional) The interface for interacting with the OVSDB
|
|
||||||
# Allowed values: vsctl, native
|
|
||||||
# Defaults to $::os_service_default
|
|
||||||
#
|
|
||||||
# [*purge_config*]
|
# [*purge_config*]
|
||||||
# (optional) Whether to set only the specified config options
|
# (optional) Whether to set only the specified config options
|
||||||
# in the ovs config.
|
# in the ovs config.
|
||||||
@ -178,6 +173,11 @@
|
|||||||
# [*of_interface*]
|
# [*of_interface*]
|
||||||
# (optional) This option is deprecated an has no effect
|
# (optional) This option is deprecated an has no effect
|
||||||
#
|
#
|
||||||
|
# [*ovsdb_interface*]
|
||||||
|
# (optional) The interface for interacting with the OVSDB
|
||||||
|
# Allowed values: vsctl, native
|
||||||
|
# Defaults to undef
|
||||||
|
#
|
||||||
class neutron::agents::ml2::ovs (
|
class neutron::agents::ml2::ovs (
|
||||||
$package_ensure = 'present',
|
$package_ensure = 'present',
|
||||||
$enabled = true,
|
$enabled = true,
|
||||||
@ -205,7 +205,6 @@ class neutron::agents::ml2::ovs (
|
|||||||
$tun_peer_patch_port = $::os_service_default,
|
$tun_peer_patch_port = $::os_service_default,
|
||||||
$datapath_type = $::os_service_default,
|
$datapath_type = $::os_service_default,
|
||||||
$vhostuser_socket_dir = $::os_service_default,
|
$vhostuser_socket_dir = $::os_service_default,
|
||||||
$ovsdb_interface = $::os_service_default,
|
|
||||||
$purge_config = false,
|
$purge_config = false,
|
||||||
$enable_dpdk = false,
|
$enable_dpdk = false,
|
||||||
$enable_security_group = $::os_service_default,
|
$enable_security_group = $::os_service_default,
|
||||||
@ -214,6 +213,7 @@ class neutron::agents::ml2::ovs (
|
|||||||
$tunnel_csum = $::os_service_default,
|
$tunnel_csum = $::os_service_default,
|
||||||
# DEPRECATED
|
# DEPRECATED
|
||||||
$of_interface = undef,
|
$of_interface = undef,
|
||||||
|
$ovsdb_interface = undef,
|
||||||
) {
|
) {
|
||||||
|
|
||||||
include neutron::deps
|
include neutron::deps
|
||||||
@ -267,10 +267,6 @@ class neutron::agents::ml2::ovs (
|
|||||||
warning('of_interface is deprecated and will be removed in the future')
|
warning('of_interface is deprecated and will be removed in the future')
|
||||||
}
|
}
|
||||||
|
|
||||||
if ! (is_service_default($ovsdb_interface)) and ! ($ovsdb_interface =~ /^(vsctl|native)$/) {
|
|
||||||
fail('A value of $ovsdb_interface is incorrect. The allowed values are vsctl and native')
|
|
||||||
}
|
|
||||||
|
|
||||||
resources { 'neutron_agent_ovs':
|
resources { 'neutron_agent_ovs':
|
||||||
purge => $purge_config,
|
purge => $purge_config,
|
||||||
}
|
}
|
||||||
@ -304,6 +300,14 @@ class neutron::agents::ml2::ovs (
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# TODO(tobias.urdin): Remove in V release.
|
||||||
|
if $ovsdb_interface != undef {
|
||||||
|
warning('ovsdb_interface is deprecated and has no effect')
|
||||||
|
}
|
||||||
|
neutron_agent_ovs {
|
||||||
|
'ovs/ovsdb_interface': ensure => absent;
|
||||||
|
}
|
||||||
|
|
||||||
neutron_agent_ovs {
|
neutron_agent_ovs {
|
||||||
'agent/polling_interval': value => $polling_interval;
|
'agent/polling_interval': value => $polling_interval;
|
||||||
'agent/l2_population': value => $l2_population;
|
'agent/l2_population': value => $l2_population;
|
||||||
@ -320,7 +324,6 @@ class neutron::agents::ml2::ovs (
|
|||||||
'ovs/integration_bridge': value => $integration_bridge;
|
'ovs/integration_bridge': value => $integration_bridge;
|
||||||
'ovs/datapath_type': value => $datapath_type;
|
'ovs/datapath_type': value => $datapath_type;
|
||||||
'ovs/vhostuser_socket_dir': value => $vhostuser_socket_dir;
|
'ovs/vhostuser_socket_dir': value => $vhostuser_socket_dir;
|
||||||
'ovs/ovsdb_interface': value => $ovsdb_interface;
|
|
||||||
'ovs/of_interface': value => $of_interface;
|
'ovs/of_interface': value => $of_interface;
|
||||||
'securitygroup/enable_security_group': value => $enable_security_group;
|
'securitygroup/enable_security_group': value => $enable_security_group;
|
||||||
}
|
}
|
||||||
|
@ -0,0 +1,4 @@
|
|||||||
|
---
|
||||||
|
deprecations:
|
||||||
|
- |
|
||||||
|
The neutron::agents::ml2::ovs::ovsdb_interface is deprecated and has no effect.
|
@ -49,7 +49,6 @@ describe 'neutron::agents::ml2::ovs' do
|
|||||||
should contain_neutron_agent_ovs('agent/tunnel_csum').with_value(['<SERVICE DEFAULT>'])
|
should contain_neutron_agent_ovs('agent/tunnel_csum').with_value(['<SERVICE DEFAULT>'])
|
||||||
should contain_neutron_agent_ovs('ovs/datapath_type').with_value(['<SERVICE DEFAULT>'])
|
should contain_neutron_agent_ovs('ovs/datapath_type').with_value(['<SERVICE DEFAULT>'])
|
||||||
should contain_neutron_agent_ovs('ovs/vhostuser_socket_dir').with_value(['<SERVICE DEFAULT>'])
|
should contain_neutron_agent_ovs('ovs/vhostuser_socket_dir').with_value(['<SERVICE DEFAULT>'])
|
||||||
should contain_neutron_agent_ovs('ovs/ovsdb_interface').with_value(['<SERVICE DEFAULT>'])
|
|
||||||
should contain_neutron_agent_ovs('ovs/ovsdb_timeout').with_value('<SERVICE DEFAULT>')
|
should contain_neutron_agent_ovs('ovs/ovsdb_timeout').with_value('<SERVICE DEFAULT>')
|
||||||
should contain_neutron_agent_ovs('ovs/of_connect_timeout').with_value('<SERVICE DEFAULT>')
|
should contain_neutron_agent_ovs('ovs/of_connect_timeout').with_value('<SERVICE DEFAULT>')
|
||||||
should contain_neutron_agent_ovs('ovs/of_request_timeout').with_value('<SERVICE DEFAULT>')
|
should contain_neutron_agent_ovs('ovs/of_request_timeout').with_value('<SERVICE DEFAULT>')
|
||||||
@ -311,25 +310,6 @@ describe 'neutron::agents::ml2::ovs' do
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
context 'when supplying ovsdb_interface' do
|
|
||||||
context 'with incorrect value' do
|
|
||||||
before :each do
|
|
||||||
params.merge!(:ovsdb_interface => 'random')
|
|
||||||
end
|
|
||||||
|
|
||||||
it { should raise_error(Puppet::Error, /A value of \$ovsdb_interface is incorrect. The allowed values are vsctl and native/) }
|
|
||||||
end
|
|
||||||
|
|
||||||
context 'with supported value' do
|
|
||||||
before :each do
|
|
||||||
params.merge!(:ovsdb_interface => 'native')
|
|
||||||
end
|
|
||||||
it 'should configure ovsdb_interface for ovs' do
|
|
||||||
should contain_neutron_agent_ovs('ovs/ovsdb_interface').with_value('native')
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
context 'when enabling dpdk with manage vswitch disabled' do
|
context 'when enabling dpdk with manage vswitch disabled' do
|
||||||
before :each do
|
before :each do
|
||||||
params.merge!(:enable_dpdk => true, :manage_vswitch => false)
|
params.merge!(:enable_dpdk => true, :manage_vswitch => false)
|
||||||
|
Loading…
Reference in New Issue
Block a user