public class NodeQueueLoadMonitor extends Object implements ClusterMonitor
| Modifier and Type | Class and Description |
|---|---|
static class |
NodeQueueLoadMonitor.LoadComparator
The comparator used to specify the metric against which the load
of two Nodes are compared.
|
| Constructor and Description |
|---|
NodeQueueLoadMonitor(long nodeComputationInterval,
NodeQueueLoadMonitor.LoadComparator comparator) |
| Modifier and Type | Method and Description |
|---|---|
void |
addNode(List<org.apache.hadoop.yarn.server.api.protocolrecords.NMContainerStatus> containerStatuses,
RMNode rmNode) |
QueueLimitCalculator |
getThresholdCalculator() |
void |
initThresholdCalculator(float sigma,
int limitMin,
int limitMax) |
void |
removeNode(RMNode removedRMNode) |
List<org.apache.hadoop.yarn.api.records.NodeId> |
selectLeastLoadedNodes(int k)
Returns 'K' of the least Loaded Node Ids as ordered list.
|
List<org.apache.hadoop.yarn.api.records.NodeId> |
selectNodes()
Returns all Node Ids as ordered list from Least to Most Loaded.
|
void |
updateNode(RMNode rmNode) |
void |
updateNodeResource(RMNode rmNode,
org.apache.hadoop.yarn.api.records.ResourceOption resourceOption) |
public NodeQueueLoadMonitor(long nodeComputationInterval,
NodeQueueLoadMonitor.LoadComparator comparator)
public QueueLimitCalculator getThresholdCalculator()
public void initThresholdCalculator(float sigma,
int limitMin,
int limitMax)
public void addNode(List<org.apache.hadoop.yarn.server.api.protocolrecords.NMContainerStatus> containerStatuses, RMNode rmNode)
addNode in interface ClusterMonitorpublic void removeNode(RMNode removedRMNode)
removeNode in interface ClusterMonitorpublic void updateNode(RMNode rmNode)
updateNode in interface ClusterMonitorpublic void updateNodeResource(RMNode rmNode, org.apache.hadoop.yarn.api.records.ResourceOption resourceOption)
updateNodeResource in interface ClusterMonitorpublic List<org.apache.hadoop.yarn.api.records.NodeId> selectNodes()
public List<org.apache.hadoop.yarn.api.records.NodeId> selectLeastLoadedNodes(int k)
k - max number of nodes to returnCopyright © 2008–2022 Apache Software Foundation. All rights reserved.