This adds a semaphore scoped to the network ID of a port
creation in ML2 to ensure that all workers on a single server
only try to allocate an IP for that network one at a time.
This will alleviate the deadlock error retry mechanism being
exceeded due to the related bug. It reduces the number of contenders
for a single IP allocation from number of workers to number of servers.
It will unblock the switch to pluggable ipam while the IP allocation
strategy is being revamped to be less racey.
Partial-Bug: #1543094
Change-Id: Ieafdd640777d4654fcd0ebb65ace25c30151c412
(cherry picked from commit db817a9e39dbed10383cb2c70c0f95d4b1795aec)
Reviewed: https:/ /review. openstack. org/314810 /git.openstack. org/cgit/ openstack/ neutron/ commit/ ?id=c871a43383e 6bd40a358087663 267da41b7bf1ec
Committed: https:/
Submitter: Jenkins
Branch: stable/mitaka
commit c871a43383e6bd4 0a358087663267d a41b7bf1ec
Author: Kevin Benton <email address hidden>
Date: Tue Apr 5 23:06:00 2016 -0700
Add semaphore to ML2 create_port db operation
This adds a semaphore scoped to the network ID of a port
creation in ML2 to ensure that all workers on a single server
only try to allocate an IP for that network one at a time.
This will alleviate the deadlock error retry mechanism being
exceeded due to the related bug. It reduces the number of contenders
for a single IP allocation from number of workers to number of servers.
It will unblock the switch to pluggable ipam while the IP allocation
strategy is being revamped to be less racey.
Partial-Bug: #1543094 54fcd0ebb65ace2 5c30151c412 0383cb2c70c0f95 d4b1795aec)
Change-Id: Ieafdd640777d46
(cherry picked from commit db817a9e39dbed1