diff --git a/neutron/conf/common.py b/neutron/conf/common.py index c820b3c5d78..30b09a14aab 100644 --- a/neutron/conf/common.py +++ b/neutron/conf/common.py @@ -77,7 +77,12 @@ core_opts = [ "without providing a CIDR or subnetpool ID will be " "given a CIDR via the Prefix Delegation mechanism. " "Note that enabling PD will override the behavior of " - "the default IPv6 subnetpool.")), + "the default IPv6 subnetpool."), + deprecated_for_removal=True, + deprecated_since='2023.2', + deprecated_reason=("The Dibbler client used for this feature " + "is no longer maintained. See LP#1916428"), + ), cfg.IntOpt('dhcp_lease_duration', default=86400, help=_("DHCP lease duration (in seconds). Use -1 to tell " "dnsmasq to use infinite lease times.")), diff --git a/neutron/conf/experimental.py b/neutron/conf/experimental.py index 463ab4a88ba..dbb13ec8206 100644 --- a/neutron/conf/experimental.py +++ b/neutron/conf/experimental.py @@ -17,11 +17,16 @@ from neutron._i18n import _ EXPERIMENTAL_CFG_GROUP = 'experimental' EXPERIMENTAL_LINUXBRIDGE = 'linuxbridge' +EXPERIMENTAL_IPV6_PD = 'ipv6_pd_enabled' experimental_opts = [ cfg.BoolOpt(EXPERIMENTAL_LINUXBRIDGE, default=False, help=_('Enable execution of the experimental Linuxbridge ' 'agent.')), + cfg.BoolOpt(EXPERIMENTAL_IPV6_PD, + default=False, + help=_('Enable execution of the experimental IPv6 Prefix ' + 'Delegation functionality in the L3 agent.')), ] diff --git a/neutron/db/db_base_plugin_v2.py b/neutron/db/db_base_plugin_v2.py index d80e7b3fc7f..95a7d2277ea 100644 --- a/neutron/db/db_base_plugin_v2.py +++ b/neutron/db/db_base_plugin_v2.py @@ -51,8 +51,10 @@ from sqlalchemy import not_ from neutron._i18n import _ from neutron.api.rpc.agentnotifiers import l3_rpc_agent_api from neutron.common import _constants +from neutron.common import experimental from neutron.common import ipv6_utils from neutron.common import utils +from neutron.conf import experimental as c_exp from neutron.db import db_base_plugin_common from neutron.db import ipam_pluggable_backend from neutron.db import models_v2 @@ -156,7 +158,17 @@ class NeutronDbPluginV2(db_base_plugin_common.DbBasePluginCommon, result_filters=None) return super(NeutronDbPluginV2, cls).__new__(cls, *args, **kwargs) + @staticmethod + def _validate_ipv6_pd(): + try: + if cfg.CONF.ipv6_pd_enabled: + experimental.validate_experimental_enabled( + c_exp.EXPERIMENTAL_IPV6_PD) + except cfg.NoSuchOptError: + return + def __init__(self): + self._validate_ipv6_pd() self.set_ipam_backend() if (cfg.CONF.notify_nova_on_port_status_changes or cfg.CONF.notify_nova_on_port_data_changes): diff --git a/releasenotes/notes/mark_ipv6_pd_enabled_as_experimental-c9bfe343a0beb334.yaml b/releasenotes/notes/mark_ipv6_pd_enabled_as_experimental-c9bfe343a0beb334.yaml new file mode 100644 index 00000000000..b340343261d --- /dev/null +++ b/releasenotes/notes/mark_ipv6_pd_enabled_as_experimental-c9bfe343a0beb334.yaml @@ -0,0 +1,7 @@ +--- +deprecations: + - | + "ipv6_pd_enabled" has been marked as deprecated and marked as experimental. + To continue using it, deployers have to set to True the "ipv6_pd_enabled" + option in the "experimental" section of neutron.conf. See + `Dibbler project concluded `_.