Add support for [ovn] ovn_l3_scheduler

Change-Id: I394fce8bd7ac149b2513c0edd6156b7371877241
This commit is contained in:
Takashi Kajinami
2024-10-19 22:54:42 +09:00
parent a09db1dceb
commit e2e499d0d5
3 changed files with 16 additions and 0 deletions

View File

@@ -69,6 +69,11 @@
# that are no longer in Neutron.
# Defaults to $facts['os_service_default']
#
# [*ovn_l3_scheduler*]
# (optional) The OVN L3 Scheduler type used to schedule router gateway ports
# on hypervisors/chassis.
# Defaults to $facts['os_service_default']
#
# [*ovn_metadata_enabled*]
# (optional) Whether to enable metadata service in OVN.
# Type: boolean
@@ -191,6 +196,7 @@ class neutron::plugins::ml2::ovn(
$ovsdb_retry_max_interval = $facts['os_service_default'],
$ovsdb_probe_interval = $facts['os_service_default'],
$neutron_sync_mode = $facts['os_service_default'],
$ovn_l3_scheduler = $facts['os_service_default'],
$ovn_metadata_enabled = $facts['os_service_default'],
$dvr_enabled = $facts['os_service_default'],
$disable_ovn_dhcp_for_baremetal_ports = $facts['os_service_default'],
@@ -242,6 +248,7 @@ class neutron::plugins::ml2::ovn(
'ovn/ovsdb_retry_max_interval' : value => $ovsdb_retry_max_interval;
'ovn/ovsdb_probe_interval' : value => $ovsdb_probe_interval;
'ovn/neutron_sync_mode' : value => $neutron_sync_mode;
'ovn/ovn_l3_scheduler' : value => $ovn_l3_scheduler;
'ovn/ovn_metadata_enabled' : value => $ovn_metadata_enabled;
'ovn/enable_distributed_floating_ip' : value => $dvr_enabled;
'ovn/disable_ovn_dhcp_for_baremetal_ports': value => $disable_ovn_dhcp_for_baremetal_ports;

View File

@@ -0,0 +1,5 @@
---
features:
- |
The new ``neutron::plugins::ml2::ovn::ovn_l3_scheduler`` parameter has
been added.

View File

@@ -23,6 +23,7 @@ describe 'neutron::plugins::ml2::ovn' do
:ovsdb_retry_max_interval => '<SERVICE DEFAULT>',
:ovsdb_probe_interval => '<SERVICE DEFAULT>',
:neutron_sync_mode => '<SERVICE DEFAULT>',
:ovn_l3_scheduler => '<SERVICE DEFAULT>',
:ovn_metadata_enabled => '<SERVICE DEFAULT>',
:dvr_enabled => '<SERVICE DEFAULT>',
:disable_ovn_dhcp_for_baremetal_ports => '<SERVICE DEFAULT>',
@@ -70,6 +71,7 @@ describe 'neutron::plugins::ml2::ovn' do
should contain_neutron_plugin_ml2('ovn/ovsdb_retry_max_interval').with_value(p[:ovsdb_retry_max_interval])
should contain_neutron_plugin_ml2('ovn/ovsdb_probe_interval').with_value(p[:ovsdb_probe_interval])
should contain_neutron_plugin_ml2('ovn/neutron_sync_mode').with_value(p[:neutron_sync_mode])
should contain_neutron_plugin_ml2('ovn/ovn_l3_scheduler').with_value(p[:ovn_l3_scheduler])
should contain_neutron_plugin_ml2('ovn/ovn_metadata_enabled').with_value(p[:ovn_metadata_enabled])
should contain_neutron_plugin_ml2('ovn/enable_distributed_floating_ip').with_value(p[:dvr_enabled])
should contain_neutron_plugin_ml2('ovn/disable_ovn_dhcp_for_baremetal_ports').with_value(p[:disable_ovn_dhcp_for_baremetal_ports])
@@ -108,6 +110,7 @@ describe 'neutron::plugins::ml2::ovn' do
:ovsdb_retry_max_interval => 180,
:ovsdb_probe_interval => 60000,
:neutron_sync_mode => 'log',
:ovn_l3_scheduler => 'leastloaded',
:ovn_metadata_enabled => true,
:dvr_enabled => false,
:disable_ovn_dhcp_for_baremetal_ports => false,
@@ -141,6 +144,7 @@ describe 'neutron::plugins::ml2::ovn' do
should contain_neutron_plugin_ml2('ovn/ovsdb_retry_max_interval').with_value(p[:ovsdb_retry_max_interval])
should contain_neutron_plugin_ml2('ovn/ovsdb_probe_interval').with_value(p[:ovsdb_probe_interval])
should contain_neutron_plugin_ml2('ovn/neutron_sync_mode').with_value(p[:neutron_sync_mode])
should contain_neutron_plugin_ml2('ovn/ovn_l3_scheduler').with_value(p[:ovn_l3_scheduler])
should contain_neutron_plugin_ml2('ovn/ovn_metadata_enabled').with_value(p[:ovn_metadata_enabled])
should contain_neutron_plugin_ml2('ovn/enable_distributed_floating_ip').with_value(p[:dvr_enabled])
should contain_neutron_plugin_ml2('ovn/disable_ovn_dhcp_for_baremetal_ports').with_value(p[:disable_ovn_dhcp_for_baremetal_ports])