|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FSQueue
@InterfaceAudience.Private @InterfaceStability.Unstable public abstract class FSQueue
| Field Summary | |
|---|---|
protected FSParentQueue |
parent
|
protected SchedulingPolicy |
policy
|
protected org.apache.hadoop.yarn.factories.RecordFactory |
recordFactory
|
protected FairScheduler |
scheduler
|
| Constructor Summary | |
|---|---|
FSQueue(String name,
FairScheduler scheduler,
FSParentQueue parent)
|
|
| Method Summary | |
|---|---|
protected boolean |
assignContainerPreCheck(FSSchedulerNode node)
Helper method to check if the queue should attempt assigning resources |
abstract void |
collectSchedulerApplications(Collection<org.apache.hadoop.yarn.api.records.ApplicationAttemptId> apps)
Adds all applications in the queue and its subqueues to the given collection. |
Set<String> |
getAccessibleNodeLabels()
Get labels can be accessed of this queue labels={*}, means this queue can access any label labels={ }, means this queue cannot access any label except node without label labels={a, b, c} means this queue can access a or b or c |
abstract List<FSQueue> |
getChildQueues()
Gets the children of this queue, if any. |
String |
getDefaultNodeLabelExpression()
Get default label expression of this queue. |
org.apache.hadoop.yarn.api.records.Resource |
getFairShare()
Get the fair share assigned to this Schedulable. |
float |
getFairSharePreemptionThreshold()
|
long |
getFairSharePreemptionTimeout()
|
org.apache.hadoop.yarn.api.records.Resource |
getMaxShare()
Maximum Resource share assigned to the schedulable. |
FSQueueMetrics |
getMetrics()
Get the queue metrics |
org.apache.hadoop.yarn.api.records.Resource |
getMinShare()
Minimum Resource share assigned to the schedulable. |
long |
getMinSharePreemptionTimeout()
|
String |
getName()
Name of job/queue, used for debugging as well as for breaking ties in scheduling order deterministically. |
abstract int |
getNumRunnableApps()
Return the number of apps for which containers can be allocated. |
FSParentQueue |
getParent()
|
SchedulingPolicy |
getPolicy()
|
org.apache.hadoop.yarn.api.records.Priority |
getPriority()
Job priority for jobs in FIFO queues; meaningless for QueueSchedulables. |
org.apache.hadoop.yarn.api.records.QueueInfo |
getQueueInfo(boolean includeChildQueues,
boolean recursive)
Get queue information |
String |
getQueueName()
Get the queue name |
long |
getStartTime()
Start time for jobs in FIFO queues; meaningless for QueueSchedulables. |
org.apache.hadoop.yarn.api.records.Resource |
getSteadyFairShare()
Get the steady fair share assigned to this Schedulable. |
ResourceWeights |
getWeights()
Job/queue weight in fair sharing. |
boolean |
hasAccess(org.apache.hadoop.yarn.api.records.QueueACL acl,
org.apache.hadoop.security.UserGroupInformation user)
|
boolean |
isActive()
Returns true if queue has at least one app running. |
abstract void |
recomputeShares()
Recomputes the shares for all child queues and applications based on this queue's current share |
void |
setFairShare(org.apache.hadoop.yarn.api.records.Resource fairShare)
Assign a fair share to this Schedulable. |
void |
setFairSharePreemptionThreshold(float fairSharePreemptionThreshold)
|
void |
setFairSharePreemptionTimeout(long fairSharePreemptionTimeout)
|
void |
setMinSharePreemptionTimeout(long minSharePreemptionTimeout)
|
abstract void |
setPolicy(SchedulingPolicy policy)
|
void |
setSteadyFairShare(org.apache.hadoop.yarn.api.records.Resource steadyFairShare)
|
protected void |
throwPolicyDoesnotApplyException(SchedulingPolicy policy)
|
String |
toString()
Convenient toString implementation for debugging. |
void |
updatePreemptionVariables()
Update the min/fair share preemption timeouts and threshold for this queue. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.apache.hadoop.yarn.server.resourcemanager.scheduler.Queue |
|---|
getActiveUsersManager, getQueueUserAclInfo, recoverContainer |
| Methods inherited from interface org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.Schedulable |
|---|
assignContainer, getDemand, getResourceUsage, preemptContainer, updateDemand |
| Field Detail |
|---|
protected final FairScheduler scheduler
protected final FSParentQueue parent
protected final org.apache.hadoop.yarn.factories.RecordFactory recordFactory
protected SchedulingPolicy policy
| Constructor Detail |
|---|
public FSQueue(String name,
FairScheduler scheduler,
FSParentQueue parent)
| Method Detail |
|---|
public String getName()
Schedulable
getName in interface Schedulablepublic String getQueueName()
Queue
getQueueName in interface Queuepublic SchedulingPolicy getPolicy()
public FSParentQueue getParent()
protected void throwPolicyDoesnotApplyException(SchedulingPolicy policy)
throws AllocationConfigurationException
AllocationConfigurationException
public abstract void setPolicy(SchedulingPolicy policy)
throws AllocationConfigurationException
AllocationConfigurationExceptionpublic ResourceWeights getWeights()
Schedulable
getWeights in interface Schedulablepublic org.apache.hadoop.yarn.api.records.Resource getMinShare()
Schedulable
getMinShare in interface Schedulablepublic org.apache.hadoop.yarn.api.records.Resource getMaxShare()
Schedulable
getMaxShare in interface Schedulablepublic long getStartTime()
Schedulable
getStartTime in interface Schedulablepublic org.apache.hadoop.yarn.api.records.Priority getPriority()
Schedulable
getPriority in interface Schedulable
public org.apache.hadoop.yarn.api.records.QueueInfo getQueueInfo(boolean includeChildQueues,
boolean recursive)
Queue
getQueueInfo in interface QueueincludeChildQueues - include child queues?recursive - recursively get child queue information?
public FSQueueMetrics getMetrics()
Queue
getMetrics in interface Queuepublic org.apache.hadoop.yarn.api.records.Resource getFairShare()
getFairShare in interface Schedulablepublic void setFairShare(org.apache.hadoop.yarn.api.records.Resource fairShare)
Schedulable
setFairShare in interface Schedulablepublic org.apache.hadoop.yarn.api.records.Resource getSteadyFairShare()
public void setSteadyFairShare(org.apache.hadoop.yarn.api.records.Resource steadyFairShare)
public boolean hasAccess(org.apache.hadoop.yarn.api.records.QueueACL acl,
org.apache.hadoop.security.UserGroupInformation user)
hasAccess in interface Queuepublic long getFairSharePreemptionTimeout()
public void setFairSharePreemptionTimeout(long fairSharePreemptionTimeout)
public long getMinSharePreemptionTimeout()
public void setMinSharePreemptionTimeout(long minSharePreemptionTimeout)
public float getFairSharePreemptionThreshold()
public void setFairSharePreemptionThreshold(float fairSharePreemptionThreshold)
public abstract void recomputeShares()
public void updatePreemptionVariables()
public abstract List<FSQueue> getChildQueues()
public abstract void collectSchedulerApplications(Collection<org.apache.hadoop.yarn.api.records.ApplicationAttemptId> apps)
apps - the collection to add the applications topublic abstract int getNumRunnableApps()
protected boolean assignContainerPreCheck(FSSchedulerNode node)
public boolean isActive()
public String toString()
toString in class Objectpublic Set<String> getAccessibleNodeLabels()
Queue
getAccessibleNodeLabels in interface Queuepublic String getDefaultNodeLabelExpression()
Queue
getDefaultNodeLabelExpression in interface Queue
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||