[ovn metadata] Add more tunable parameters

For ml2 conf these are already added as part of [1], these
parameters are also needed in ovn metadata agent config
file, this patch takes care of it.

[1] https://review.opendev.org/q/I9a93b65aa5dbf4bca934aec82aad2f7f6ab3d73c

Change-Id: Ie0f7d0029412a16e4d9d43f408be97794b3518c0
(cherry picked from commit 68a4d9a53d)
(cherry picked from commit 53fd3e801c)
Conflicts: spec/classes/neutron_agents_ovn_metadata_spec.rb
(cherry picked from commit 3677b7aa1d)
This commit is contained in:
yatinkarel 2022-07-08 20:51:15 +05:30
parent 4456238f97
commit 9a9bdac5ac
3 changed files with 27 additions and 0 deletions

View File

@ -86,6 +86,15 @@
# (optional) Timeout in seconds for the OVSDB connection transaction
# Defaults to $::os_service_default
#
# [*ovsdb_retry_max_interval*]
# (optional) Max interval in seconds between each retry to get the OVN NB
# and SB IDLs.
# Defaults to $::os_service_default.
#
# [*ovsdb_probe_interval*]
# (optional) The probe interval for the OVSDB session in milliseconds.
# Defaults to $::os_service_default.
#
# [*root_helper*]
# (optional) Use "sudo neutron-rootwrap /etc/neutron/rootwrap.conf" to use the real
# root filter facility. Change to "sudo" to skip the filtering and just run the command
@ -133,6 +142,8 @@ class neutron::agents::ovn_metadata (
$ovn_sb_certificate = $::os_service_default,
$ovn_sb_ca_cert = $::os_service_default,
$ovsdb_connection_timeout = $::os_service_default,
$ovsdb_retry_max_interval = $::os_service_default,
$ovsdb_probe_interval = $::os_service_default,
$root_helper = 'sudo neutron-rootwrap /etc/neutron/rootwrap.conf',
$root_helper_daemon = $::os_service_default,
$state_path = '/var/lib/neutron',
@ -165,6 +176,8 @@ class neutron::agents::ovn_metadata (
'agent/root_helper_daemon': value => $root_helper_daemon;
'ovs/ovsdb_connection': value => $ovsdb_connection;
'ovs/ovsdb_connection_timeout': value => $ovsdb_connection_timeout;
'ovn/ovsdb_retry_max_interval': value => $ovsdb_retry_max_interval;
'ovn/ovsdb_probe_interval': value => $ovsdb_probe_interval;
'ovn/ovn_sb_connection': value => $ovn_sb_connection;
'ovn/ovn_sb_private_key': value => $ovn_sb_private_key;
'ovn/ovn_sb_certificate': value => $ovn_sb_certificate;

View File

@ -0,0 +1,12 @@
---
features:
- |
The ``neutron::agents::ovn_metadata`` class now supports
the following two new parameters.
- ``ovsdb_probe_interval`` parameter to configure
``[ovn]ovsdb_probe_interval`` in ovn metadata agent config
file.
- ``ovsdb_retry_max_interval`` parameter to configure
``[ovn]ovsdb_retry_max_interval`` in ovn metadata agent
config file.

View File

@ -68,6 +68,8 @@ describe 'neutron::agents::ovn_metadata' do
should contain_ovn_metadata_agent_config('ovs/ovsdb_connection').with(:value => params[:ovsdb_connection])
should contain_ovn_metadata_agent_config('ovn/ovn_sb_connection').with(:value => '<SERVICE DEFAULT>')
should contain_ovn_metadata_agent_config('ovn/ovn_remote_probe_interval').with(:value => '<SERVICE DEFAULT>')
should contain_ovn_metadata_agent_config('ovn/ovsdb_retry_max_interval').with(:value => '<SERVICE DEFAULT>')
should contain_ovn_metadata_agent_config('ovn/ovsdb_probe_interval').with(:value => '<SERVICE DEFAULT>')
end
end