bug
1041669
the fact that these plugins ever cleared this field is probably just a
misunderstanding of how the field is supposed to be used, as I don't think
it ever makes sense for the L2 plugin logic to change this field.
Change-Id: Ie9579e2f88d322cfdce51a2ca126f4dfab680022
try:
port = session.query(models_v2.Port).filter_by(id=port_id).one()
port['status'] = status
- if status == constants.PORT_STATUS_DOWN:
- port['device_id'] = ''
- port['device_owner'] = ''
session.merge(port)
session.flush()
except exc.NoResultFound:
try:
port = session.query(models_v2.Port).filter_by(id=port_id).one()
port['status'] = status
- if status == constants.PORT_STATUS_DOWN:
- port['device_id'] = ''
- port['device_owner'] = ''
session.merge(port)
session.flush()
except exc.NoResultFound: