Save error status in DB

Temporary enable saving error status in db, because
there is a lot of logic which relaes to error status of node.
Need to split node status to 2 different fields:
node.state and node.status

Change-Id: Id75f05826dd8116c8bc768709f7779b4aeac0167
Blueprint: graph-concept-extension
This commit is contained in:
Bulat Gaifullin 2016-08-25 00:46:50 +03:00
parent 06686519a0
commit 5f91aa224e
1 changed files with 2 additions and 2 deletions

View File

@ -576,8 +576,8 @@ def _update_nodes(transaction, nodes_instances, nodes_params):
# to delete node from cluster
objects.Node.remove_from_cluster(node)
elif new_status == 'error':
# do not update status of node, only set
# appropriate error type
# TODO(bgaifullin) do not persist status in DB
node.status = new_status
node.error_type = node_params.get(
'error_type', consts.NODE_ERRORS.deploy
)