@Assaf, I don't think we need to go that far. Take a look at [1]. I think something similar could be done. Like I said, we solved this within the context of a subnetpool and the solution could be extended to the context of a Network (this bug) or a router.
My point was that we can't just use a traditional DB constraint for this. A little extra work needs to be done to lock and synchronize between workers around the network.
@Assaf, I don't think we need to go that far. Take a look at [1]. I think something similar could be done. Like I said, we solved this within the context of a subnetpool and the solution could be extended to the context of a Network (this bug) or a router.
My point was that we can't just use a traditional DB constraint for this. A little extra work needs to be done to lock and synchronize between workers around the network.
[1] https:/ /github. com/openstack/ neutron/ blob/68276dc961 4d47d028e46c35b f62668e253af18b /neutron/ ipam/subnet_ alloc.py# L44