Fix update_port() so that it's done within the transaction
Fixes bug 1185152 Change-Id: I192991650a3562c73af550ec2288d1285412825c
This commit is contained in:
parent
915cbf92d2
commit
c9d5b51379
@ -1379,9 +1379,9 @@ class QuantumDbPluginV2(quantum_plugin_base_v2.QuantumPluginBaseV2):
|
||||
ip_address=ip['ip_address'], subnet_id=ip['subnet_id'],
|
||||
expiration=self._default_allocation_expiration())
|
||||
context.session.add(allocated)
|
||||
# Remove all attributes in p which are not in the port DB model
|
||||
# and then update the port
|
||||
port.update(self._filter_non_model_columns(p, models_v2.Port))
|
||||
# Remove all attributes in p which are not in the port DB model
|
||||
# and then update the port
|
||||
port.update(self._filter_non_model_columns(p, models_v2.Port))
|
||||
|
||||
return self._make_port_dict(port)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user