Fix missing common options

Since the dependent patch was merged in Neutron, we need to call
the register_common_config_options method explicitly to register common
options like oslo.log options.

This change updates the job template according to the tested runtimes
for Zed. This is required to remove Python 3.6/7 because these are no
longer supported.

Also, now unit tests are executed with current master code of Neutron,
instead of the latest release, so that we can run test with any
unreleased change in Neutron.

Closes-Bug: #1977980
Related-Bug: #1968606
Depends-on: https://review.opendev.org/c/openstack/neutron/+/837392
Change-Id: I1ac3557fcd6eba187d52686345040c5fdfb4f7e9
changes/41/845141/9
Takashi Kajinami 2022-06-09 01:57:21 +09:00
parent 6872c3bd95
commit fb7ff9f45b
6 changed files with 30 additions and 2 deletions

View File

@ -1,4 +1,4 @@
[gerrit]
host=review.opendev.org
port=29418
project=openstack/networking-l2gw.git
project=x/networking-l2gw.git

View File

@ -1,7 +1,7 @@
- project:
templates:
- check-requirements
- openstack-python3-victoria-jobs-neutron
- openstack-python3-zed-jobs-neutron
- build-openstack-docs-pti
check:
jobs:
@ -12,6 +12,28 @@
# TODO: make this voting again
- openstack-tox-lower-constraints:
voting: false
- openstack-tox-pep8:
required-projects:
- x/networking-l2gw
- openstack-tox-py38:
required-projects:
- openstack/neutron
- x/networking-l2gw
- openstack-tox-py39:
required-projects:
- openstack/neutron
- x/networking-l2gw
gate:
jobs:
- networking-l2gw-tempest-dummy
- openstack-tox-pep8:
required-projects:
- x/networking-l2gw
- openstack-tox-py38:
required-projects:
- openstack/neutron
- x/networking-l2gw
- openstack-tox-py39:
required-projects:
- openstack/neutron
- x/networking-l2gw

View File

@ -20,11 +20,13 @@ from neutron_lib.api import validators
from neutron.api import extensions
from neutron.api.v2 import resource_helper
from neutron.common import config as common_config
from networking_l2gw import extensions as l2gw_extensions
from networking_l2gw.services.l2gateway.common import constants
from networking_l2gw.services.l2gateway.common import l2gw_validators
common_config.register_common_config_options()
extensions.append_api_extensions_path(l2gw_extensions.__path__)
RESOURCE_ATTRIBUTE_MAP = {

View File

@ -32,6 +32,7 @@ class L2gatewayAgentService(n_rpc.Service):
def main():
common_config.register_common_config_options()
config.register_ovsdb_opts_helper(cfg.CONF)
agent_config.register_agent_state_opts_helper(cfg.CONF)
common_config.init(sys.argv[1:])

View File

@ -31,6 +31,7 @@ from neutron_lib.agent import topics
from neutron_lib import context as neutron_context
from networking_l2gw.services.l2gateway import agent_scheduler
from networking_l2gw.services.l2gateway.common import config as l2gw_config
from networking_l2gw.services.l2gateway.common import constants as srv_const
from networking_l2gw.services.l2gateway.common import topics as l2gw_topics
from networking_l2gw.services.l2gateway.service_drivers import agent_api
@ -69,6 +70,7 @@ class TestAgentScheduler(base.BaseTestCase):
def setUp(self):
super(TestAgentScheduler, self).setUp()
l2gw_config.register_l2gw_opts_helper()
cfg.CONF.set_override('core_plugin',
"neutron.plugins.ml2.plugin.Ml2Plugin")
self.plugin = FakePlugin()

View File

@ -79,6 +79,7 @@ deps =
# run locally (not in the gate) using editable mode
# https://pip.pypa.io/en/stable/reference/pip_install/#editable-installs
commands =
pip install -q -e "git+https://opendev.org/x/networking-l2gw#egg=networking_l2gw"
pip install -q -e "git+https://opendev.org/openstack/neutron#egg=neutron"
[testenv:py3-dev]