@InterfaceAudience.Private @InterfaceStability.Unstable public class AppSchedulingInfo extends Object
| Constructor and Description |
|---|
AppSchedulingInfo(org.apache.hadoop.yarn.api.records.ApplicationAttemptId appAttemptId,
String user,
Queue queue,
ActiveUsersManager activeUsersManager,
long epoch,
ResourceUsage appResourceUsage) |
| Modifier and Type | Method and Description |
|---|---|
List<org.apache.hadoop.yarn.api.records.ResourceRequest> |
allocate(NodeType type,
SchedulerNode node,
org.apache.hadoop.yarn.api.records.Priority priority,
org.apache.hadoop.yarn.api.records.ResourceRequest request,
org.apache.hadoop.yarn.api.records.Container containerAllocated)
Resources have been allocated to this application by the resource
scheduler.
|
org.apache.hadoop.yarn.api.records.ResourceRequest |
cloneResourceRequest(org.apache.hadoop.yarn.api.records.ResourceRequest request) |
void |
decreaseContainer(SchedContainerChangeRequest decreaseRequest) |
List<org.apache.hadoop.yarn.api.records.ResourceRequest> |
getAllResourceRequests() |
boolean |
getAndResetBlacklistChanged() |
org.apache.hadoop.yarn.api.records.ApplicationAttemptId |
getApplicationAttemptId() |
org.apache.hadoop.yarn.api.records.ApplicationId |
getApplicationId() |
Set<String> |
getBlackList() |
Set<String> |
getBlackListCopy() |
SchedContainerChangeRequest |
getIncreaseRequest(org.apache.hadoop.yarn.api.records.NodeId nodeId,
org.apache.hadoop.yarn.api.records.Priority priority,
org.apache.hadoop.yarn.api.records.ContainerId containerId) |
Map<org.apache.hadoop.yarn.api.records.ContainerId,SchedContainerChangeRequest> |
getIncreaseRequests(org.apache.hadoop.yarn.api.records.NodeId nodeId,
org.apache.hadoop.yarn.api.records.Priority priority) |
long |
getNewContainerId() |
Collection<org.apache.hadoop.yarn.api.records.Priority> |
getPriorities() |
String |
getQueueName() |
Set<String> |
getRequestedPartitions() |
org.apache.hadoop.yarn.api.records.Resource |
getResource(org.apache.hadoop.yarn.api.records.Priority priority) |
org.apache.hadoop.yarn.api.records.ResourceRequest |
getResourceRequest(org.apache.hadoop.yarn.api.records.Priority priority,
String resourceName) |
Map<String,org.apache.hadoop.yarn.api.records.ResourceRequest> |
getResourceRequests(org.apache.hadoop.yarn.api.records.Priority priority) |
String |
getUser() |
boolean |
hasIncreaseRequest(org.apache.hadoop.yarn.api.records.NodeId nodeId) |
void |
increaseContainer(SchedContainerChangeRequest increaseRequest) |
boolean |
isPending() |
boolean |
isPlaceBlacklisted(String resourceName,
boolean blacklistedBySystem)
Returns if the place (node/rack today) is either blacklisted by the
application (user) or the system
|
void |
move(Queue newQueue) |
void |
recoverContainer(RMContainer rmContainer) |
boolean |
removeIncreaseRequest(org.apache.hadoop.yarn.api.records.NodeId nodeId,
org.apache.hadoop.yarn.api.records.Priority priority,
org.apache.hadoop.yarn.api.records.ContainerId containerId) |
void |
setQueue(Queue queue) |
void |
stop() |
void |
transferStateFromPreviousAppSchedulingInfo(AppSchedulingInfo appInfo) |
boolean |
updateIncreaseRequests(List<SchedContainerChangeRequest> increaseRequests)
return true if any of the existing increase requests are updated,
false if none of them are updated
|
void |
updatePlacesBlacklistedByApp(List<String> blacklistAdditions,
List<String> blacklistRemovals)
The ApplicationMaster is updating the placesBlacklistedByApp used for
containers other than AMs.
|
void |
updatePlacesBlacklistedBySystem(List<String> blacklistAdditions,
List<String> blacklistRemovals)
Update the list of places that are blacklisted by the system.
|
boolean |
updateResourceRequests(List<org.apache.hadoop.yarn.api.records.ResourceRequest> requests,
boolean recoverPreemptedRequestForAContainer)
The ApplicationMaster is updating resource requirements for the
application, by asking for more resources and releasing resources acquired
by the application.
|
public AppSchedulingInfo(org.apache.hadoop.yarn.api.records.ApplicationAttemptId appAttemptId,
String user,
Queue queue,
ActiveUsersManager activeUsersManager,
long epoch,
ResourceUsage appResourceUsage)
public org.apache.hadoop.yarn.api.records.ApplicationId getApplicationId()
public org.apache.hadoop.yarn.api.records.ApplicationAttemptId getApplicationAttemptId()
public String getUser()
public long getNewContainerId()
public String getQueueName()
public boolean isPending()
public boolean hasIncreaseRequest(org.apache.hadoop.yarn.api.records.NodeId nodeId)
public Map<org.apache.hadoop.yarn.api.records.ContainerId,SchedContainerChangeRequest> getIncreaseRequests(org.apache.hadoop.yarn.api.records.NodeId nodeId, org.apache.hadoop.yarn.api.records.Priority priority)
public boolean updateIncreaseRequests(List<SchedContainerChangeRequest> increaseRequests)
public boolean removeIncreaseRequest(org.apache.hadoop.yarn.api.records.NodeId nodeId,
org.apache.hadoop.yarn.api.records.Priority priority,
org.apache.hadoop.yarn.api.records.ContainerId containerId)
public SchedContainerChangeRequest getIncreaseRequest(org.apache.hadoop.yarn.api.records.NodeId nodeId, org.apache.hadoop.yarn.api.records.Priority priority, org.apache.hadoop.yarn.api.records.ContainerId containerId)
public boolean updateResourceRequests(List<org.apache.hadoop.yarn.api.records.ResourceRequest> requests, boolean recoverPreemptedRequestForAContainer)
requests - resources to be acquiredrecoverPreemptedRequestForAContainer - recover ResourceRequest on preemptionpublic void updatePlacesBlacklistedByApp(List<String> blacklistAdditions, List<String> blacklistRemovals)
blacklistAdditions - resources to be added to the userBlacklistblacklistRemovals - resources to be removed from the userBlacklistpublic void updatePlacesBlacklistedBySystem(List<String> blacklistAdditions, List<String> blacklistRemovals)
blacklistAdditions - resources to be added to placesBlacklistedBySystemblacklistRemovals - resources to be removed from placesBlacklistedBySystempublic boolean getAndResetBlacklistChanged()
public Collection<org.apache.hadoop.yarn.api.records.Priority> getPriorities()
public Map<String,org.apache.hadoop.yarn.api.records.ResourceRequest> getResourceRequests(org.apache.hadoop.yarn.api.records.Priority priority)
public List<org.apache.hadoop.yarn.api.records.ResourceRequest> getAllResourceRequests()
public org.apache.hadoop.yarn.api.records.ResourceRequest getResourceRequest(org.apache.hadoop.yarn.api.records.Priority priority,
String resourceName)
public org.apache.hadoop.yarn.api.records.Resource getResource(org.apache.hadoop.yarn.api.records.Priority priority)
public boolean isPlaceBlacklisted(String resourceName, boolean blacklistedBySystem)
resourceName - the resourcenameblacklistedBySystem - true if it should check amBlacklistpublic void increaseContainer(SchedContainerChangeRequest increaseRequest)
public void decreaseContainer(SchedContainerChangeRequest decreaseRequest)
public List<org.apache.hadoop.yarn.api.records.ResourceRequest> allocate(NodeType type, SchedulerNode node, org.apache.hadoop.yarn.api.records.Priority priority, org.apache.hadoop.yarn.api.records.ResourceRequest request, org.apache.hadoop.yarn.api.records.Container containerAllocated)
public void move(Queue newQueue)
public void stop()
public void setQueue(Queue queue)
public void transferStateFromPreviousAppSchedulingInfo(AppSchedulingInfo appInfo)
public void recoverContainer(RMContainer rmContainer)
public org.apache.hadoop.yarn.api.records.ResourceRequest cloneResourceRequest(org.apache.hadoop.yarn.api.records.ResourceRequest request)
Copyright © 2017 Apache Software Foundation. All Rights Reserved.