@ThreadSafe @DefaultImplementation(value=SingleJobTaskGroupQueue.class) public interface PendingTaskGroupQueue
Scheduler
enqueues the TaskGroups to schedule to this queue.
SchedulerRunner
refers to this queue when scheduling TaskGroups.Modifier and Type | Method and Description |
---|---|
void |
close()
Closes and cleans up this queue.
|
Optional<ScheduledTaskGroup> |
dequeue()
Dequeues the next TaskGroup to be scheduled.
|
void |
enqueue(ScheduledTaskGroup scheduledTaskGroup)
Enqueues a TaskGroup to this PQ.
|
boolean |
isEmpty()
Checks whether there are schedulable TaskGroups in the queue or not.
|
void |
onJobScheduled(PhysicalPlan physicalPlanForJob)
Registers a job to this queue in case the queue needs to understand the topology of the job DAG.
|
void |
removeTaskGroupsAndDescendants(String stageIdOfTaskGroups)
Removes a stage and its descendant stages from this queue.
|
void enqueue(ScheduledTaskGroup scheduledTaskGroup)
scheduledTaskGroup
- to enqueue.Optional<ScheduledTaskGroup> dequeue()
void onJobScheduled(PhysicalPlan physicalPlanForJob)
physicalPlanForJob
- the job to schedule.void removeTaskGroupsAndDescendants(String stageIdOfTaskGroups)
stageIdOfTaskGroups
- for the stage to begin the removal recursively.boolean isEmpty()
void close()
Copyright © 2018. All rights reserved.