You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@yunikorn.apache.org by GitBox <gi...@apache.org> on 2021/09/17 23:45:28 UTC

[GitHub] [incubator-yunikorn-site] craigcondit commented on a change in pull request #81: [YUNIKORN-852] Document resource weighting in node sorting policies.

craigcondit commented on a change in pull request #81:
URL: https://github.com/apache/incubator-yunikorn-site/pull/81#discussion_r711402794



##########
File path: docs/user_guide/sorting_policies.md
##########
@@ -146,6 +146,33 @@ Resources of the same type are compared for the nodes.
 This results in a node with the highest utilisation to be considered first for assigning new allocation.
 Resulting in a high(er) utilisation of a small(er) number of nodes, better suited for cloud deployments.   
 
+## Resource weighting
+Node sorting policies may use the utilization of a node to determine ordering. Because nodes can have several unique
+resource types, a node's utilization is determined by a weighted average of its individual resource types. Resource
+weighting can be customized by using the `resourceweights` section of `nodesortpolicy`. If `resourceweights` is not
+present or empty, the default configuration sets the weight of both `vcore` and `memory` equally to `1.0`. All other
+resource types are ignored. Only resource types explicitly mentioned will have a weight.

Review comment:
       Updated.

##########
File path: docs/user_guide/sorting_policies.md
##########
@@ -146,6 +146,33 @@ Resources of the same type are compared for the nodes.
 This results in a node with the highest utilisation to be considered first for assigning new allocation.
 Resulting in a high(er) utilisation of a small(er) number of nodes, better suited for cloud deployments.   
 
+## Resource weighting
+Node sorting policies may use the utilization of a node to determine ordering. Because nodes can have several unique
+resource types, a node's utilization is determined by a weighted average of its individual resource types. Resource
+weighting can be customized by using the `resourceweights` section of `nodesortpolicy`. If `resourceweights` is not
+present or empty, the default configuration sets the weight of both `vcore` and `memory` equally to `1.0`. All other
+resource types are ignored. Only resource types explicitly mentioned will have a weight.
+
+For example, in the default configuration, if a node has `90%` of its CPU and `50%` of its memory allocated, the node
+will be considered to be `70%` utilized.
+
+The following configuration entry sets the weight of `vcore` to `4.0` and `memory` to `1.0`. This will weight CPU
+usage four times higher than memory usage:
+```yaml
+partitions:
+  - name: default
+    nodesortpolicy:
+      resourceweights:
+        vcore: 4.0
+        memory: 1.0
+```
+
+With this configuration, In this example, if a node has `90%` of its CPU and `50%` of its memory allocated, the node
+will be considered to be `82%` utilized.
+
+Note that weights are relative to each other, so specifying weights of `{ 4.0, 1.0 }` is equivalent to

Review comment:
       Updated.

##########
File path: docs/user_guide/sorting_policies.md
##########
@@ -146,6 +146,33 @@ Resources of the same type are compared for the nodes.
 This results in a node with the highest utilisation to be considered first for assigning new allocation.
 Resulting in a high(er) utilisation of a small(er) number of nodes, better suited for cloud deployments.   
 
+## Resource weighting
+Node sorting policies may use the utilization of a node to determine ordering. Because nodes can have several unique
+resource types, a node's utilization is determined by a weighted average of its individual resource types. Resource
+weighting can be customized by using the `resourceweights` section of `nodesortpolicy`. If `resourceweights` is not
+present or empty, the default configuration sets the weight of both `vcore` and `memory` equally to `1.0`. All other
+resource types are ignored. Only resource types explicitly mentioned will have a weight.
+
+For example, in the default configuration, if a node has `90%` of its CPU and `50%` of its memory allocated, the node
+will be considered to be `70%` utilized.
+
+The following configuration entry sets the weight of `vcore` to `4.0` and `memory` to `1.0`. This will weight CPU
+usage four times higher than memory usage:
+```yaml
+partitions:
+  - name: default
+    nodesortpolicy:
+      resourceweights:
+        vcore: 4.0
+        memory: 1.0

Review comment:
       Updated.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@yunikorn.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org