Add Neutron QoS support
- Enable QoS related service plugins, ml2 extensions and extension drivers - Add noop tests Implements: blueprint support-qos Change-Id: I7393649eb624998c3560f151a3490b8f8611816b
This commit is contained in:
parent
84e09f39cb
commit
74780f5bf9
@ -4,15 +4,23 @@ $use_neutron = hiera('use_neutron', false)
|
||||
|
||||
if $use_neutron {
|
||||
|
||||
$openstack_network_hash = hiera_hash('openstack_network', { })
|
||||
$neutron_config = hiera_hash('neutron_config')
|
||||
$openstack_network_hash = hiera_hash('openstack_network', { })
|
||||
$neutron_config = hiera_hash('neutron_config')
|
||||
$neutron_advanced_config = hiera_hash('neutron_advanced_configuration', { })
|
||||
$enable_qos = pick($neutron_advanced_config['neutron_qos'], false)
|
||||
|
||||
$core_plugin = 'neutron.plugins.ml2.plugin.Ml2Plugin'
|
||||
$service_plugins = [
|
||||
$core_plugin = 'neutron.plugins.ml2.plugin.Ml2Plugin'
|
||||
$default_service_plugins = [
|
||||
'neutron.services.l3_router.l3_router_plugin.L3RouterPlugin',
|
||||
'neutron.services.metering.metering_plugin.MeteringPlugin',
|
||||
]
|
||||
|
||||
if $enable_qos {
|
||||
$service_plugins = concat($default_service_plugins, ['qos'])
|
||||
} else {
|
||||
$service_plugins = $default_service_plugins
|
||||
}
|
||||
|
||||
$rabbit_hash = hiera_hash('rabbit_hash', {})
|
||||
$ceilometer_hash = hiera_hash('ceilometer', {})
|
||||
$network_scheme = hiera_hash('network_scheme', {})
|
||||
|
@ -48,6 +48,7 @@ if $use_neutron {
|
||||
$neutron_advanced_config = hiera_hash('neutron_advanced_configuration', { })
|
||||
$l2_population = try_get_value($neutron_advanced_config, 'neutron_l2_pop', false)
|
||||
$dvr = try_get_value($neutron_advanced_config, 'neutron_dvr', false)
|
||||
$enable_qos = pick($neutron_advanced_config['neutron_qos'], false)
|
||||
$segmentation_type = try_get_value($neutron_config, 'L2/segmentation_type')
|
||||
|
||||
if $compute and ! $dvr {
|
||||
@ -56,6 +57,12 @@ if $use_neutron {
|
||||
$do_floating = true
|
||||
}
|
||||
|
||||
if $enable_qos {
|
||||
$extensions = ['qos']
|
||||
} else {
|
||||
$extensions = undef
|
||||
}
|
||||
|
||||
$bridge_mappings = generate_bridge_mappings($neutron_config, $network_scheme, {
|
||||
'do_floating' => $do_floating,
|
||||
'do_tenant' => true,
|
||||
@ -127,6 +134,7 @@ if $use_neutron {
|
||||
firewall_driver => $firewall_driver,
|
||||
datapath_type => $ovs_datapath_type,
|
||||
vhostuser_socket_dir => $ovs_vhostuser_socket_dir,
|
||||
extensions => $extensions,
|
||||
manage_vswitch => false,
|
||||
manage_service => true,
|
||||
enabled => true,
|
||||
|
@ -91,6 +91,15 @@ if $use_neutron {
|
||||
$dvr = pick($neutron_advanced_config['neutron_dvr'], false)
|
||||
$l3_ha = pick($neutron_advanced_config['neutron_l3_ha'], false)
|
||||
$l3agent_failover = $l3_ha ? { true => false, default => true}
|
||||
$enable_qos = pick($neutron_advanced_config['neutron_qos'], false)
|
||||
|
||||
if $enable_qos {
|
||||
$qos_notification_drivers = 'message_queue'
|
||||
$extension_drivers = ['port_security', 'qos']
|
||||
} else {
|
||||
$qos_notification_drivers = undef
|
||||
$extension_drivers = ['port_security']
|
||||
}
|
||||
|
||||
$nova_auth_user = pick($nova_hash['user'], 'nova')
|
||||
$nova_auth_password = $nova_hash['user_password']
|
||||
@ -170,7 +179,6 @@ if $use_neutron {
|
||||
}
|
||||
|
||||
$vxlan_group = '224.0.0.1'
|
||||
$extension_drivers = ['port_security']
|
||||
$tenant_network_types = ['flat', $network_type]
|
||||
|
||||
class { 'neutron::plugins::ml2':
|
||||
@ -213,6 +221,7 @@ if $use_neutron {
|
||||
rpc_workers => $service_workers,
|
||||
|
||||
router_distributed => $dvr,
|
||||
qos_notification_drivers => $qos_notification_drivers,
|
||||
enabled => true,
|
||||
manage_service => true,
|
||||
}
|
||||
|
@ -22,6 +22,16 @@ describe manifest do
|
||||
context 'with Neutron' do
|
||||
neutron_config = Noop.hiera('neutron_config')
|
||||
openstack_network_hash = Noop.hiera('openstack_network', { })
|
||||
adv_neutron_config = Noop.hiera_hash('neutron_advanced_configuration', {})
|
||||
enable_qos = adv_neutron_config.fetch('neutron_qos', false)
|
||||
service_plugins = [
|
||||
'neutron.services.l3_router.l3_router_plugin.L3RouterPlugin',
|
||||
'neutron.services.metering.metering_plugin.MeteringPlugin',
|
||||
]
|
||||
|
||||
if enable_qos
|
||||
service_plugins.concat(['qos'])
|
||||
end
|
||||
|
||||
it {
|
||||
verbose = openstack_network_hash['verbose']
|
||||
@ -48,10 +58,7 @@ describe manifest do
|
||||
it { should contain_class('neutron').with('base_mac' => neutron_config['L2']['base_mac'])}
|
||||
it { should contain_class('neutron').with('core_plugin' => 'neutron.plugins.ml2.plugin.Ml2Plugin')}
|
||||
|
||||
it { should contain_class('neutron').with('service_plugins' => [
|
||||
'neutron.services.l3_router.l3_router_plugin.L3RouterPlugin',
|
||||
'neutron.services.metering.metering_plugin.MeteringPlugin',
|
||||
])}
|
||||
it { should contain_class('neutron').with('service_plugins' => service_plugins)}
|
||||
|
||||
it { should contain_class('neutron').with('bind_host' => bind_host)}
|
||||
|
||||
|
@ -46,6 +46,13 @@ describe manifest do
|
||||
l2_population = adv_neutron_config.fetch('neutron_l2_pop', false)
|
||||
dpdk_config = Noop.hiera_hash('dpdk', {})
|
||||
enable_dpdk = dpdk_config.fetch('enabled', false)
|
||||
enable_qos = adv_neutron_config.fetch('neutron_qos', false)
|
||||
|
||||
if enable_qos
|
||||
it { should contain_class('neutron::agents::ml2::ovs').with(
|
||||
'extensions' => ['qos']
|
||||
)}
|
||||
end
|
||||
|
||||
if segmentation_type == 'vlan'
|
||||
network_type = 'vlan'
|
||||
|
@ -56,6 +56,15 @@ describe manifest do
|
||||
ml2_sriov_value = 'rm DAEMON_ARGS'
|
||||
end
|
||||
|
||||
enable_qos = adv_neutron_config.fetch('neutron_qos', false)
|
||||
|
||||
if enable_qos
|
||||
extension_drivers = extension_drivers.concat(['qos'])
|
||||
it { should contain_class('neutron::server').with(
|
||||
'qos_notification_drivers' => 'message_queue',
|
||||
)}
|
||||
end
|
||||
|
||||
if segmentation_type == 'vlan'
|
||||
network_type = 'vlan'
|
||||
network_vlan_ranges_physnet2 = pnets.fetch('physnet2',{}).fetch('vlan_range')
|
||||
|
Loading…
Reference in New Issue
Block a user