Log ERROR power state in node_power_action()

Power driver can returns ERROR state. Log this error and do not
break requested action (this can be unknown valid state).

Partial-Bug: #1358816
Change-Id: I9b26440671cb44b58016dfd796adbd8fedd483ae
This commit is contained in:
Yuriy Zveryanskyy 2014-08-28 15:10:09 +03:00
parent 7a35462661
commit 37b71282a9
1 changed files with 5 additions and 0 deletions

View File

@ -92,6 +92,11 @@ def node_power_action(task, state):
{'state': curr_state})
return
if curr_state == states.ERROR:
# be optimistic and continue action
LOG.warn(_LW("Driver returns ERROR power state for node %s."),
node.uuid)
# Set the target_power_state and clear any last_error, since we're
# starting a new operation. This will expose to other processes
# and clients that work is in progress.