Fix bad CDMC update on reception of service.update

When we receive a incoming 'service.update' notification
from nova, with disabled: false, we should set the related
compute node status to ENABLED.

Change-Id: Ib8075a5cf786f81ec41423805433f83ae721cbbd
Closes-bug: #1650485
This commit is contained in:
David TARDIVEL
2016-12-16 10:11:38 +01:00
parent 345083e090
commit 1bc6b0e605
4 changed files with 37 additions and 2 deletions

View File

@@ -121,7 +121,7 @@ class NovaNotification(base.NotificationEndpoint):
if node_data['forced_down'] else element.ServiceState.ONLINE.value)
node.status = (
element.ServiceState.DISABLED.value
if node_data['host'] else element.ServiceState.ENABLED.value)
if node_data['disabled'] else element.ServiceState.ENABLED.value)
def create_compute_node(self, node_hostname):
"""Update the compute node by querying the Nova API."""