Add tenant and label name to Launch failed error

This change improves the launch failure logs to include the tenant
and the label name of the failed node.

Change-Id: I13ddfb1333a4865d3b117aa68fda14d3123fe451
This commit is contained in:
Tristan Cacqueray 2023-08-23 18:05:16 +00:00
parent d6c2422bc3
commit 8dc55c231f

View File

@ -95,7 +95,10 @@ class NodeLauncher(threading.Thread,
statsd_key = 'error.quota'
except Exception as e:
self.log.exception(
"Launch failed for node %s:", self.node.hostname)
"Launch failed for node %s: tenant=%s label=%s",
self.node.hostname,
self.node.tenant_name,
self.node.label)
self.node.state = zk.FAILED
self.zk.storeNode(self.node)