public class FairSchedulerPlanFollower extends AbstractSchedulerPlanFollower
clock, plans, scheduler| Constructor and Description |
|---|
FairSchedulerPlanFollower() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addReservationQueue(String planQueueName,
Queue queue,
String currResId)
Add a new reservation queue for reservation currResId for this planQueue.
|
protected void |
createDefaultReservationQueue(String planQueueName,
Queue queue,
String defReservationId)
Creates the default reservation queue for use when no reservation is used
for applications submitted to this planQueue.
|
protected List<? extends Queue> |
getChildReservationQueues(Queue queue)
Get a list of reservation queues for this planQueue.
|
protected Queue |
getPlanQueue(String planQueueName)
Get queue associated with reservable queue named.
|
protected org.apache.hadoop.yarn.api.records.Resource |
getPlanResources(Plan plan,
Queue queue,
org.apache.hadoop.yarn.api.records.Resource clusterResources)
Get plan resources for this planQueue.
|
protected String |
getReservationIdFromQueueName(String resQueueName) |
protected String |
getReservationQueueName(String planQueueName,
String reservationQueueName) |
protected org.apache.hadoop.yarn.api.records.Resource |
getReservationQueueResourceIfExists(Plan plan,
org.apache.hadoop.yarn.api.records.ReservationId reservationId)
Get reservation queue resources if it exists otherwise return null.
|
void |
init(org.apache.hadoop.yarn.util.Clock clock,
ResourceScheduler sched,
Collection<Plan> plans)
Init function that configures the PlanFollower, by providing:
|
cleanupExpiredQueues, getReservedResources, run, setPlans, setQueueEntitlement, sortByDelta, synchronizePlanpublic void init(org.apache.hadoop.yarn.util.Clock clock,
ResourceScheduler sched,
Collection<Plan> plans)
PlanFollowerinit in interface PlanFollowerinit in class AbstractSchedulerPlanFollowerclock - a reference to the system clock.sched - a reference to the underlying schedulerplans - references to the plans we should keep synchronized at every
time tick.protected Queue getPlanQueue(String planQueueName)
AbstractSchedulerPlanFollowergetPlanQueue in class AbstractSchedulerPlanFollowerplanQueueName - name of the reservable queueprotected List<? extends Queue> getChildReservationQueues(Queue queue)
AbstractSchedulerPlanFollowergetChildReservationQueues in class AbstractSchedulerPlanFollowerqueue - the queue for the current Planprotected void addReservationQueue(String planQueueName, Queue queue, String currResId)
AbstractSchedulerPlanFolloweraddReservationQueue in class AbstractSchedulerPlanFollowerplanQueueName - name of the reservable queue.queue - the queue for the current Plan.currResId - curr reservationId.protected void createDefaultReservationQueue(String planQueueName, Queue queue, String defReservationId)
AbstractSchedulerPlanFollowercreateDefaultReservationQueue in class AbstractSchedulerPlanFollowerplanQueueName - name of the reservable queuequeue - the queue for the current PlandefReservationId - name of the default ReservationQueueprotected org.apache.hadoop.yarn.api.records.Resource getPlanResources(Plan plan, Queue queue, org.apache.hadoop.yarn.api.records.Resource clusterResources)
AbstractSchedulerPlanFollowergetPlanResources in class AbstractSchedulerPlanFollowerplan - the current Plan being consideredqueue - the queue for the current PlanclusterResources - the resources available in the clusterPlanprotected org.apache.hadoop.yarn.api.records.Resource getReservationQueueResourceIfExists(Plan plan, org.apache.hadoop.yarn.api.records.ReservationId reservationId)
AbstractSchedulerPlanFollowergetReservationQueueResourceIfExists in class AbstractSchedulerPlanFollowerplan - the current Plan being consideredreservationId - the identifier of the reservationprotected String getReservationQueueName(String planQueueName, String reservationQueueName)
getReservationQueueName in class AbstractSchedulerPlanFollowerprotected String getReservationIdFromQueueName(String resQueueName)
getReservationIdFromQueueName in class AbstractSchedulerPlanFollowerCopyright © 2008–2024 Apache Software Foundation. All rights reserved.