The definition of label in YARN-796 is pretty clear,

*         Node Label  label that describes a node. Node can have multiple labels

*         Label expression  logical combination of labels (using &&  and, ||  
or, !  not)
With this definition (without considering the implementation), a node label 
could be treated as a Boolean type attribute of a node. Assuming the 
administrator define label1, label2, label3 in the system, and associate node1 
with "label1, label2", this means the value of attribute label1 and label2 for 
node1 is true, while the value of attribute label3 will be false for node1.

In current Yarn implementation, seems the resource partitioning has been 
treated as the primary use case for node label, and some design/implementation 
of node label mainly consider on the partitioning case, even the multiple label 
support has been disabled in  YARN-2694. To cover the workload resource request 
use case, YARN-3409 was proposed while the description/example of constraint 
node label in YARN-3409 seems more like a String type attribute for a node 
instead of Boolean type anymore. I got confused about node label.

>From my view, node label is one attribute of a node, and it could be used for 
>different scheduling scenarios. No matter resource partitioning or job 
>scheduling constraints, a node label is just a label on a node. For 
>partitioning, we can have one object calling partition or resource group 
>representing the group of nodes with certain label; for workload scheduling 
>constraints purpose, we may want to extend the current application level 
>constraint to be container level constraint, for one application, the master 
>may request one type of resource while the slave request another type of 
>resource.

Comments?

Lei Guo
Senior Architect, Huawei Canada Research Centre

Reply via email to