@InterfaceAudience.LimitedPrivate(value="yarn") @InterfaceStability.Evolving public class FifoScheduler extends Object implements ResourceScheduler, Configurable
Modifier and Type | Field and Description |
---|---|
protected Map<ApplicationAttemptId,FiCaSchedulerApp> |
applications |
Constructor and Description |
---|
FifoScheduler() |
Modifier and Type | Method and Description |
---|---|
Allocation |
allocate(ApplicationAttemptId applicationAttemptId,
List<ResourceRequest> ask,
List<ContainerId> release,
List<String> blacklistAdditions,
List<String> blacklistRemovals)
The main api between the ApplicationMaster and the Scheduler.
|
boolean |
checkAccess(UserGroupInformation callerUGI,
QueueACL acl,
String queueName)
Check if the user has permission to perform the operation.
|
Configuration |
getConf()
Return the configuration used by this object.
|
Resource |
getMaximumResourceCapability()
Get maximum allocatable
Resource . |
Resource |
getMinimumResourceCapability()
Get minimum allocatable
Resource . |
SchedulerNodeReport |
getNodeReport(NodeId nodeId)
Get node resource usage report.
|
int |
getNumClusterNodes()
Get the number of nodes available in the cluster.
|
QueueInfo |
getQueueInfo(String queueName,
boolean includeChildQueues,
boolean recursive)
Get queue information
|
List<QueueUserACLInfo> |
getQueueUserAclInfo()
Get acls for queues for current user.
|
QueueMetrics |
getRootQueueMetrics()
Get the root queue for the scheduler.
|
SchedulerAppReport |
getSchedulerAppInfo(ApplicationAttemptId applicationAttemptId)
Get the Scheduler app for a given app attempt Id.
|
void |
handle(SchedulerEvent event) |
void |
recover(RMStateStore.RMState state) |
void |
reinitialize(Configuration conf,
RMContext rmContext)
Re-initialize the
ResourceScheduler . |
void |
setConf(Configuration conf)
Set the configuration to be used by this object.
|
protected Map<ApplicationAttemptId,FiCaSchedulerApp> applications
public void setConf(Configuration conf)
Configurable
setConf
in interface Configurable
public Configuration getConf()
Configurable
getConf
in interface Configurable
public Resource getMinimumResourceCapability()
YarnScheduler
Resource
.getMinimumResourceCapability
in interface YarnScheduler
public int getNumClusterNodes()
YarnScheduler
getNumClusterNodes
in interface YarnScheduler
public Resource getMaximumResourceCapability()
YarnScheduler
Resource
.getMaximumResourceCapability
in interface YarnScheduler
public void reinitialize(Configuration conf, RMContext rmContext) throws IOException
ResourceScheduler
ResourceScheduler
.reinitialize
in interface ResourceScheduler
conf
- configurationIOException
public Allocation allocate(ApplicationAttemptId applicationAttemptId, List<ResourceRequest> ask, List<ContainerId> release, List<String> blacklistAdditions, List<String> blacklistRemovals)
YarnScheduler
allocate
in interface YarnScheduler
Allocation
for the applicationpublic SchedulerAppReport getSchedulerAppInfo(ApplicationAttemptId applicationAttemptId)
YarnScheduler
getSchedulerAppInfo
in interface YarnScheduler
applicationAttemptId
- the id of the application attemptpublic void handle(SchedulerEvent event)
handle
in interface EventHandler<SchedulerEvent>
public QueueInfo getQueueInfo(String queueName, boolean includeChildQueues, boolean recursive)
YarnScheduler
getQueueInfo
in interface YarnScheduler
queueName
- queue nameincludeChildQueues
- include child queues?recursive
- get children queues?public List<QueueUserACLInfo> getQueueUserAclInfo()
YarnScheduler
getQueueUserAclInfo
in interface YarnScheduler
public void recover(RMStateStore.RMState state)
recover
in interface Recoverable
public SchedulerNodeReport getNodeReport(NodeId nodeId)
YarnScheduler
getNodeReport
in interface YarnScheduler
SchedulerNodeReport
for the node or null
if nodeId does not point to a defined node.public QueueMetrics getRootQueueMetrics()
YarnScheduler
getRootQueueMetrics
in interface YarnScheduler
public boolean checkAccess(UserGroupInformation callerUGI, QueueACL acl, String queueName)
YarnScheduler
QueueACL.ADMINISTER_QUEUE
permission,
this user can view/modify the applications in this queuecheckAccess
in interface YarnScheduler
true
if the user has the permission,
false
otherwiseCopyright © 2013 Apache Software Foundation. All rights reserved.