This fix targets quite rare case of race condition between
port creation and subnet deletion. This usually happens
during API tests that do things quickly.
DHCP port is being created after delete_subnet checks for
DHCP ports, but before it checks for IPAllocations on subnet.
The solution is to apply retrying logic, which is really necessary
as we can't fetch new IPAllocations with the same query and within
the active transaction in mysql because of REPEATABLE READ
transaction isolation.
Reviewed: https:/ /review. openstack. org/171848 /git.openstack. org/cgit/ openstack/ neutron/ commit/ ?id=1642bca4d9c 4fee15129f74d93 300c1eab1afd29
Committed: https:/
Submitter: Jenkins
Branch: master
commit 1642bca4d9c4fee 15129f74d93300c 1eab1afd29
Author: Eugene Nikanorov <email address hidden>
Date: Thu Apr 9 01:16:18 2015 +0300
Handle race condition on subnet-delete
This fix targets quite rare case of race condition between
port creation and subnet deletion. This usually happens
during API tests that do things quickly.
DHCP port is being created after delete_subnet checks for
DHCP ports, but before it checks for IPAllocations on subnet.
The solution is to apply retrying logic, which is really necessary
as we can't fetch new IPAllocations with the same query and within
the active transaction in mysql because of REPEATABLE READ
transaction isolation.
Change-Id: Ib9da018e654cde e3b64aa38de90f1 71c92ee28ee
Closes-Bug: 1357055