← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1282925] Re: db_plugin.delete_ports() can lead to long transaction if plugin.deleete_port talks with external system

 

** Changed in: neutron
       Status: Fix Committed => Fix Released

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

Title:
  db_plugin.delete_ports() can lead to long transaction if
  plugin.deleete_port talks with external system

Status in OpenStack Neutron (virtual network service):
  Fix Released

Bug description:
  db_plugin.delete_ports() can lead to long transaction if plugin.delete_port talks with external system.
  it is observed first in nec plugin (bug 1282922), but it affects multiple plugins/drivers.

  Note that it is about delete_ports and not about delete_port.

  The detail is described in bug 1282922. Quoted from the original bug report.
  ----
  The case I observed is that delete-port from dhcp-agent (release_dhcp_port RPC call) and delete-port from delete-network API request are run in parallel. plugin.delete-port in nec plugin calls REST API call to an external controller in addition to operates on neutron database.

  After my investigation and testing, db_plugin.delete_ports() calls plugin.delete_port() under a transaction.
  https://github.com/openstack/neutron/blob/master/neutron/db/db_base_plugin_v2.py#L1367
  This means the transaction continues over API calls to external controller and it leads to a long transaction.
  When plugin.delete_ports() and plugin.delete_port() are run at the same time, even if plugin.delete_port() avoid long transaction, db operations in plugin.delete_port() is blocked and they can fail with timeout.
  ----

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


References