← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 2056558] [NEW] ``OVNL3RouterPlugin._port_update`` can be called before the LRP is created in the OVN DB

 

Public bug reported:

``OVNL3RouterPlugin._port_update`` [1] is called AFTER_UPDATE the router
port is created (for example, when a subnet is attached to a router).
This event is guaranteed to be called after the Neutron DB has the
resource (port) in the database. However, as the code highlights in the
comment, this event can be called before the OVN NB database has the LRP
resource created. The called method, ``update_router_port`` -->
``_update_router_port``, guarantees that the LRP update is executed only
when the LRP exists but the LRP read [2] does not have this
consideration.

This event should be replaced by an OVN DB event, checking the same
conditions as in [1] and guaranteeing that the LRP resource is already
created in the DB.

Example of this failure:
https://zuul.opendev.org/t/openstack/build/3f7935d7ed53473898bbf213e85dfb61/log/controller/logs/dsvm-
functional-
logs/ovn_octavia_provider.tests.functional.test_driver.TestOvnOctaviaProviderDriver.test_create_lb_custom_network/testrun.txt

[1]https://opendev.org/openstack/neutron/src/commit/e8468a6dd647fd62eac429417c7f382e8859b574/neutron/services/ovn_l3/plugin.py#L372-L381
[2]https://opendev.org/openstack/neutron/src/commit/e8468a6dd647fd62eac429417c7f382e8859b574/neutron/plugins/ml2/drivers/ovn/mech_driver/ovsdb/ovn_client.py#L1809-L1811

** Affects: neutron
     Importance: Medium
         Status: New

** Description changed:

  ``OVNL3RouterPlugin._port_update`` [1] is called AFTER_UPDATE the router
  port is created (for example, when a subnet is attached to a router).
  This event is guaranteed to be called after the Neutron DB has the
  resource (port) in the database. However, as the code highlights in the
  comment, this event can be called before the OVN NB database has the LRP
  resource created. The called method, ``update_router_port`` -->
  ``_update_router_port``, guarantees that the LRP update is executed only
  when the LRP exists but the LRP read [2] does not have this
  consideration.
  
  This event should be replaced by an OVN DB event, checking the same
  conditions as in [1] and guaranteeing that the LRP resource is already
  created in the DB.
  
+ Example of this failure:
+ https://zuul.opendev.org/t/openstack/build/3f7935d7ed53473898bbf213e85dfb61/log/controller/logs/dsvm-
+ functional-
+ logs/ovn_octavia_provider.tests.functional.test_driver.TestOvnOctaviaProviderDriver.test_create_lb_custom_network/testrun.txt
+ 
  [1]https://opendev.org/openstack/neutron/src/commit/e8468a6dd647fd62eac429417c7f382e8859b574/neutron/services/ovn_l3/plugin.py#L372-L381
  [2]https://opendev.org/openstack/neutron/src/commit/e8468a6dd647fd62eac429417c7f382e8859b574/neutron/plugins/ml2/drivers/ovn/mech_driver/ovsdb/ovn_client.py#L1809-L1811

** Changed in: neutron
   Importance: Undecided => Medium

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/2056558

Title:
  ``OVNL3RouterPlugin._port_update`` can be called before the LRP is
  created in the OVN DB

Status in neutron:
  New

Bug description:
  ``OVNL3RouterPlugin._port_update`` [1] is called AFTER_UPDATE the
  router port is created (for example, when a subnet is attached to a
  router). This event is guaranteed to be called after the Neutron DB
  has the resource (port) in the database. However, as the code
  highlights in the comment, this event can be called before the OVN NB
  database has the LRP resource created. The called method,
  ``update_router_port`` --> ``_update_router_port``, guarantees that
  the LRP update is executed only when the LRP exists but the LRP read
  [2] does not have this consideration.

  This event should be replaced by an OVN DB event, checking the same
  conditions as in [1] and guaranteeing that the LRP resource is already
  created in the DB.

  Example of this failure:
  https://zuul.opendev.org/t/openstack/build/3f7935d7ed53473898bbf213e85dfb61/log/controller/logs/dsvm-
  functional-
  logs/ovn_octavia_provider.tests.functional.test_driver.TestOvnOctaviaProviderDriver.test_create_lb_custom_network/testrun.txt

  [1]https://opendev.org/openstack/neutron/src/commit/e8468a6dd647fd62eac429417c7f382e8859b574/neutron/services/ovn_l3/plugin.py#L372-L381
  [2]https://opendev.org/openstack/neutron/src/commit/e8468a6dd647fd62eac429417c7f382e8859b574/neutron/plugins/ml2/drivers/ovn/mech_driver/ovsdb/ovn_client.py#L1809-L1811

To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/2056558/+subscriptions



Follow ups