org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair
Class FSParentQueue

java.lang.Object
  extended by org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.Schedulable
      extended by org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FSQueue
          extended by org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FSParentQueue
All Implemented Interfaces:
Queue

@InterfaceAudience.Private
@InterfaceStability.Unstable
public class FSParentQueue
extends FSQueue


Field Summary
 
Fields inherited from class org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FSQueue
parent, policy, recordFactory
 
Constructor Summary
FSParentQueue(String name, QueueManager queueMgr, FairScheduler scheduler, FSParentQueue parent)
           
 
Method Summary
 void addChildQueue(FSQueue child)
           
 org.apache.hadoop.yarn.api.records.Resource assignContainer(FSSchedulerNode node)
          Assign a container on this node if possible, and return the amount of resources assigned.
 Collection<FSQueue> getChildQueues()
          Gets the children of this queue, if any.
 org.apache.hadoop.yarn.api.records.Resource getDemand()
          Maximum number of resources required by this Schedulable.
 List<org.apache.hadoop.yarn.api.records.QueueUserACLInfo> getQueueUserAclInfo(org.apache.hadoop.security.UserGroupInformation user)
          Get queue ACLs for given user.
 org.apache.hadoop.yarn.api.records.Resource getResourceUsage()
          Get the aggregate amount of resources consumed by the schedulable.
 void recomputeShares()
          Recomputes the shares for all child queues and applications based on this queue's current share
 void setPolicy(SchedulingPolicy policy)
           
 void updateDemand()
          Refresh the Schedulable's demand and those of its children if any.
 
Methods inherited from class org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FSQueue
assignContainerPreCheck, getMaxShare, getMetrics, getMinShare, getName, getPolicy, getPriority, getQueueInfo, getQueueName, getStartTime, getWeights, hasAccess, setFairShare, throwPolicyDoesnotApplyException
 
Methods inherited from class org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.Schedulable
getFairShare, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FSParentQueue

public FSParentQueue(String name,
                     QueueManager queueMgr,
                     FairScheduler scheduler,
                     FSParentQueue parent)
Method Detail

addChildQueue

public void addChildQueue(FSQueue child)

recomputeShares

public void recomputeShares()
Description copied from class: FSQueue
Recomputes the shares for all child queues and applications based on this queue's current share

Specified by:
recomputeShares in class FSQueue

getDemand

public org.apache.hadoop.yarn.api.records.Resource getDemand()
Description copied from class: Schedulable
Maximum number of resources required by this Schedulable. This is defined as number of currently utilized resources + number of unlaunched resources (that are either not yet launched or need to be speculated).

Specified by:
getDemand in class Schedulable

getResourceUsage

public org.apache.hadoop.yarn.api.records.Resource getResourceUsage()
Description copied from class: Schedulable
Get the aggregate amount of resources consumed by the schedulable.

Specified by:
getResourceUsage in class Schedulable

updateDemand

public void updateDemand()
Description copied from class: Schedulable
Refresh the Schedulable's demand and those of its children if any.

Specified by:
updateDemand in class Schedulable

getQueueUserAclInfo

public List<org.apache.hadoop.yarn.api.records.QueueUserACLInfo> getQueueUserAclInfo(org.apache.hadoop.security.UserGroupInformation user)
Description copied from interface: Queue
Get queue ACLs for given user.

Parameters:
user - username
Returns:
queue ACLs for user

assignContainer

public org.apache.hadoop.yarn.api.records.Resource assignContainer(FSSchedulerNode node)
Description copied from class: Schedulable
Assign a container on this node if possible, and return the amount of resources assigned.

Specified by:
assignContainer in class Schedulable

getChildQueues

public Collection<FSQueue> getChildQueues()
Description copied from class: FSQueue
Gets the children of this queue, if any.

Specified by:
getChildQueues in class FSQueue

setPolicy

public void setPolicy(SchedulingPolicy policy)
               throws AllocationConfigurationException
Specified by:
setPolicy in class FSQueue
Throws:
AllocationConfigurationException


Copyright © 2014 Apache Software Foundation. All Rights Reserved.