|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface YarnScheduler
This interface is used by the components to talk to the scheduler for allocating of resources, cleaning up resources.
| Method Summary | |
|---|---|
void |
addQueue(Queue newQueue)
Add to the scheduler a new Queue. |
Allocation |
allocate(org.apache.hadoop.yarn.api.records.ApplicationAttemptId appAttemptId,
List<org.apache.hadoop.yarn.api.records.ResourceRequest> ask,
List<org.apache.hadoop.yarn.api.records.ContainerId> release,
List<String> blacklistAdditions,
List<String> blacklistRemovals)
The main api between the ApplicationMaster and the Scheduler. |
boolean |
checkAccess(org.apache.hadoop.security.UserGroupInformation callerUGI,
org.apache.hadoop.yarn.api.records.QueueACL acl,
String queueName)
Check if the user has permission to perform the operation. |
org.apache.hadoop.yarn.api.records.ApplicationResourceUsageReport |
getAppResourceUsageReport(org.apache.hadoop.yarn.api.records.ApplicationAttemptId appAttemptId)
Get a resource usage report from a given app attempt ID. |
List<org.apache.hadoop.yarn.api.records.ApplicationAttemptId> |
getAppsInQueue(String queueName)
Gets the apps under a given queue |
org.apache.hadoop.yarn.api.records.Resource |
getClusterResource()
Get the whole resource capacity of the cluster. |
org.apache.hadoop.yarn.api.records.Resource |
getMaximumResourceCapability()
Get maximum allocatable Resource. |
org.apache.hadoop.yarn.api.records.Resource |
getMinimumResourceCapability()
Get minimum allocatable Resource. |
SchedulerNodeReport |
getNodeReport(org.apache.hadoop.yarn.api.records.NodeId nodeId)
Get node resource usage report. |
int |
getNumClusterNodes()
Get the number of nodes available in the cluster. |
Set<String> |
getPlanQueues()
Gets the list of names for queues managed by the Reservation System |
org.apache.hadoop.yarn.api.records.QueueInfo |
getQueueInfo(String queueName,
boolean includeChildQueues,
boolean recursive)
Get queue information |
List<org.apache.hadoop.yarn.api.records.QueueUserACLInfo> |
getQueueUserAclInfo()
Get acls for queues for current user. |
RMContainer |
getRMContainer(org.apache.hadoop.yarn.api.records.ContainerId containerId)
Get the container for the given containerId. |
QueueMetrics |
getRootQueueMetrics()
Get the root queue for the scheduler. |
SchedulerAppReport |
getSchedulerAppInfo(org.apache.hadoop.yarn.api.records.ApplicationAttemptId appAttemptId)
Get the Scheduler app for a given app attempt Id. |
EnumSet<org.apache.hadoop.yarn.proto.YarnServiceProtos.SchedulerResourceTypes> |
getSchedulingResourceTypes()
Return a collection of the resource types that are considered when scheduling |
void |
killAllAppsInQueue(String queueName)
Terminate all applications in the specified queue. |
void |
moveAllApps(String sourceQueue,
String destQueue)
Completely drain sourceQueue of applications, by moving all of them to destQueue. |
String |
moveApplication(org.apache.hadoop.yarn.api.records.ApplicationId appId,
String newQueue)
Moves the given application to the given queue |
void |
removeQueue(String queueName)
Remove an existing queue. |
void |
setEntitlement(String queue,
QueueEntitlement entitlement)
This method increase the entitlement for current queue (must respect invariants, e.g., no overcommit of parents, non negative, etc.). |
| Methods inherited from interface org.apache.hadoop.yarn.event.EventHandler |
|---|
handle |
| Method Detail |
|---|
@InterfaceAudience.Public
@InterfaceStability.Stable
org.apache.hadoop.yarn.api.records.QueueInfo getQueueInfo(String queueName,
boolean includeChildQueues,
boolean recursive)
throws IOException
queueName - queue nameincludeChildQueues - include child queues?recursive - get children queues?
IOException@InterfaceAudience.Public @InterfaceStability.Stable List<org.apache.hadoop.yarn.api.records.QueueUserACLInfo> getQueueUserAclInfo()
@InterfaceAudience.LimitedPrivate(value="yarn") @InterfaceStability.Unstable org.apache.hadoop.yarn.api.records.Resource getClusterResource()
@InterfaceAudience.Public @InterfaceStability.Stable org.apache.hadoop.yarn.api.records.Resource getMinimumResourceCapability()
Resource.
@InterfaceAudience.Public @InterfaceStability.Stable org.apache.hadoop.yarn.api.records.Resource getMaximumResourceCapability()
Resource.
@InterfaceAudience.Public @InterfaceStability.Stable int getNumClusterNodes()
@InterfaceAudience.Public
@InterfaceStability.Stable
Allocation allocate(org.apache.hadoop.yarn.api.records.ApplicationAttemptId appAttemptId,
List<org.apache.hadoop.yarn.api.records.ResourceRequest> ask,
List<org.apache.hadoop.yarn.api.records.ContainerId> release,
List<String> blacklistAdditions,
List<String> blacklistRemovals)
appAttemptId - ask - release - blacklistAdditions - blacklistRemovals -
Allocation for the application@InterfaceAudience.LimitedPrivate(value="yarn") @InterfaceStability.Stable SchedulerNodeReport getNodeReport(org.apache.hadoop.yarn.api.records.NodeId nodeId)
nodeId -
SchedulerNodeReport for the node or null
if nodeId does not point to a defined node.@InterfaceAudience.LimitedPrivate(value="yarn") @InterfaceStability.Stable SchedulerAppReport getSchedulerAppInfo(org.apache.hadoop.yarn.api.records.ApplicationAttemptId appAttemptId)
appAttemptId - the id of the application attempt
@InterfaceAudience.LimitedPrivate(value="yarn") @InterfaceStability.Evolving org.apache.hadoop.yarn.api.records.ApplicationResourceUsageReport getAppResourceUsageReport(org.apache.hadoop.yarn.api.records.ApplicationAttemptId appAttemptId)
appAttemptId - the id of the application attempt
@InterfaceAudience.LimitedPrivate(value="yarn") @InterfaceStability.Evolving QueueMetrics getRootQueueMetrics()
boolean checkAccess(org.apache.hadoop.security.UserGroupInformation callerUGI,
org.apache.hadoop.yarn.api.records.QueueACL acl,
String queueName)
QueueACL.ADMINISTER_QUEUE permission,
this user can view/modify the applications in this queue
callerUGI - acl - queueName -
true if the user has the permission,
false otherwise@InterfaceAudience.LimitedPrivate(value="yarn") @InterfaceStability.Stable List<org.apache.hadoop.yarn.api.records.ApplicationAttemptId> getAppsInQueue(String queueName)
queueName - the name of the queue.
@InterfaceAudience.LimitedPrivate(value="yarn") @InterfaceStability.Unstable RMContainer getRMContainer(org.apache.hadoop.yarn.api.records.ContainerId containerId)
containerId -
@InterfaceAudience.LimitedPrivate(value="yarn")
@InterfaceStability.Evolving
String moveApplication(org.apache.hadoop.yarn.api.records.ApplicationId appId,
String newQueue)
throws org.apache.hadoop.yarn.exceptions.YarnException
appId - newQueue -
org.apache.hadoop.yarn.exceptions.YarnException - if the move cannot be carried out
void moveAllApps(String sourceQueue,
String destQueue)
throws org.apache.hadoop.yarn.exceptions.YarnException
sourceQueue - destQueue -
org.apache.hadoop.yarn.exceptions.YarnException
void killAllAppsInQueue(String queueName)
throws org.apache.hadoop.yarn.exceptions.YarnException
queueName - the name of queue to be drained
org.apache.hadoop.yarn.exceptions.YarnException
void removeQueue(String queueName)
throws org.apache.hadoop.yarn.exceptions.YarnException
queueName - name of the queue to remove
org.apache.hadoop.yarn.exceptions.YarnException
void addQueue(Queue newQueue)
throws org.apache.hadoop.yarn.exceptions.YarnException
newQueue - the queue being added.
org.apache.hadoop.yarn.exceptions.YarnException
void setEntitlement(String queue,
QueueEntitlement entitlement)
throws org.apache.hadoop.yarn.exceptions.YarnException
queue - the queue for which we change entitlemententitlement - the new entitlement for the queue (capacity,
maxCapacity, etc..)
org.apache.hadoop.yarn.exceptions.YarnException
Set<String> getPlanQueues()
throws org.apache.hadoop.yarn.exceptions.YarnException
org.apache.hadoop.yarn.exceptions.YarnExceptionEnumSet<org.apache.hadoop.yarn.proto.YarnServiceProtos.SchedulerResourceTypes> getSchedulingResourceTypes()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||