Reset device owner when port on agent is down
Fixes bug 1036690 Change-Id: If96d2c129a8d5f258ebf8213d3720f2a9809cce2
This commit is contained in:
parent
45e7e1f2f5
commit
97eb413b5b
@ -190,6 +190,7 @@ def set_port_status(port_id, status):
|
||||
port['status'] = status
|
||||
if status == api_common.PORT_STATUS_DOWN:
|
||||
port['device_id'] = ''
|
||||
port['device_owner'] = ''
|
||||
session.merge(port)
|
||||
session.flush()
|
||||
except exc.NoResultFound:
|
||||
|
@ -188,6 +188,7 @@ def set_port_status(port_id, status):
|
||||
port['status'] = status
|
||||
if status == api_common.PORT_STATUS_DOWN:
|
||||
port['device_id'] = ''
|
||||
port['device_owner'] = ''
|
||||
session.merge(port)
|
||||
session.flush()
|
||||
except exc.NoResultFound:
|
||||
|
Loading…
x
Reference in New Issue
Block a user