YARN-10647. Fix TestRMNodeLabelsManager failed after YARN-10501. Contributed by

Qi Zhu.
This commit is contained in:
Eric Badger 2021-02-22 18:48:14 +00:00
parent 8bca105655
commit 47420ae3ed

View File

@ -646,7 +646,9 @@ protected void internalUpdateLabelsOnNodes(
host.labels.addAll(labels);
for (Node node : host.nms.values()) {
replaceNodeForLabels(node.nodeId, node.labels, labels);
replaceLabelsForNode(node.nodeId, node.labels, labels);
if (node.labels != null && labels != null) {
replaceLabelsForNode(node.nodeId, node.labels, labels);
}
node.labels = null;
}
break;