Merge "ML2 VxlanTypeDriver: Synchronize of VxlanAllocation table"

This commit is contained in:
Jenkins 2014-05-10 09:42:00 +00:00 committed by Gerrit Code Review
commit d64b09617f

View File

@ -153,7 +153,7 @@ class VxlanTypeDriver(type_tunnel.TunnelTypeDriver):
session = db_api.get_session()
with session.begin(subtransactions=True):
# remove from table unallocated tunnels not currently allocatable
allocs = session.query(VxlanAllocation)
allocs = session.query(VxlanAllocation).with_lockmode("update")
for alloc in allocs:
try:
# see if tunnel is allocatable