← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1435852] Re: Use first() instead of one() in tunnel endpoint query

 

** Changed in: neutron
       Status: In Progress => Invalid

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

Title:
  Use first() instead of one() in tunnel endpoint query

Status in neutron:
  Invalid

Bug description:
  Consider running neutron-server in the HA mode, Thread A is trying to delete the endpoint for tunnel_ip=10.0.0.2. https://github.com/openstack/neutron/blob/master/neutron/plugins/ml2/drivers/type_tunnel.py#L243
  whereas, Thread B is trying to add the endpoint for tunnel_ip=10.0.0.2 which is already existing so it will fall in except db_exc.DBDuplicateEntry and look for ip_address. But Thread A could possibly delete it since both threads are async. In that case, the query will raise an exception if we use one() instead of first().

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


References