From d8a2f212f79ef732b58fe6b0cd80c85e213b496b Mon Sep 17 00:00:00 2001 From: Takashi Kajinami Date: Tue, 28 Nov 2023 09:42:48 +0900 Subject: [PATCH] Add [metadata_rate_limiting] options to example config files The metadata_rate_limiting options were added during the previous cycles[1] but these options were not added to the oslo.config entry points thus are still missing from the example config files. This change adds these options to the appropriate entry points so that the options are picked up by oslo-config-generator. These options were previously registered by metadata-agent which are not using these options really. This change also removes that useless registration. [1] 5f4a41326d7b1da03e1929b4fd8bcdaf69da19ab Closes-Bug: #2044896 Change-Id: Ib4bea51e24063c275737cdd769ad07c621a845f6 --- neutron/agent/metadata_agent.py | 3 --- neutron/conf/agent/ovn/metadata/config.py | 4 +++- neutron/opts.py | 8 ++++++-- 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/neutron/agent/metadata_agent.py b/neutron/agent/metadata_agent.py index 46be2e95983..feee9917340 100644 --- a/neutron/agent/metadata_agent.py +++ b/neutron/agent/metadata_agent.py @@ -33,9 +33,6 @@ def main(): meta.register_meta_conf_opts(meta.SHARED_OPTS) meta.register_meta_conf_opts(meta.UNIX_DOMAIN_METADATA_PROXY_OPTS) meta.register_meta_conf_opts(meta.METADATA_PROXY_HANDLER_OPTS) - meta.register_meta_conf_opts(meta.METADATA_RATE_LIMITING_OPTS, - cfg=cfg.CONF, - group=meta.RATE_LIMITING_GROUP) cache.register_oslo_configs(cfg.CONF) agent_conf.register_agent_state_opts_helper(cfg.CONF) service_conf.register_service_opts(service_conf.RPC_EXTRA_OPTS, cfg.CONF) diff --git a/neutron/conf/agent/ovn/metadata/config.py b/neutron/conf/agent/ovn/metadata/config.py index 0ec3380fa8d..54564c5a859 100644 --- a/neutron/conf/agent/ovn/metadata/config.py +++ b/neutron/conf/agent/ovn/metadata/config.py @@ -46,7 +46,9 @@ def list_metadata_agent_opts(): meta_conf.METADATA_PROXY_HANDLER_OPTS, meta_conf.UNIX_DOMAIN_METADATA_PROXY_OPTS) ), - ('ovs', OVS_OPTS) + ('ovs', OVS_OPTS), + (meta_conf.RATE_LIMITING_GROUP, + meta_conf.METADATA_RATE_LIMITING_OPTS) ] diff --git a/neutron/opts.py b/neutron/opts.py index 4cd89fae740..eb3baf32ced 100644 --- a/neutron/opts.py +++ b/neutron/opts.py @@ -236,7 +236,9 @@ def list_dhcp_agent_opts(): neutron.conf.agent.dhcp.DHCP_AGENT_OPTS, neutron.conf.agent.dhcp.DHCP_OPTS, neutron.conf.agent.dhcp.DNSMASQ_OPTS) - ) + ), + (meta_conf.RATE_LIMITING_GROUP, + meta_conf.METADATA_RATE_LIMITING_OPTS) ] @@ -274,7 +276,9 @@ def list_l3_agent_opts(): ('agent', neutron.conf.agent.agent_extensions_manager.AGENT_EXT_MANAGER_OPTS), ('network_log', - neutron.conf.services.logging.log_driver_opts) + neutron.conf.services.logging.log_driver_opts), + (meta_conf.RATE_LIMITING_GROUP, + meta_conf.METADATA_RATE_LIMITING_OPTS) ]