public interface OrderingPolicy<S extends SchedulableEntity>
Modifier and Type | Method and Description |
---|---|
void |
addAllSchedulableEntities(Collection<S> sc)
Add a collection of SchedulableEntities to be managed for allocation
and preemption ordering
|
void |
addSchedulableEntity(S s)
Add a SchedulableEntity to be managed for allocation and preemption
ordering
|
void |
configure(Map<String,String> conf)
Provides configuration information for the policy from the scheduler
configuration
|
void |
containerAllocated(S schedulableEntity,
RMContainer r)
The passed SchedulableEntity has been allocated the passed Container,
take appropriate action (depending on comparator, a reordering of the
SchedulableEntity may be required)
|
void |
containerReleased(S schedulableEntity,
RMContainer r)
The passed SchedulableEntity has released the passed Container,
take appropriate action (depending on comparator, a reordering of the
SchedulableEntity may be required)
|
void |
demandUpdated(S schedulableEntity)
Demand Updated for the passed schedulableEntity, reorder if needed.
|
Iterator<S> |
getAssignmentIterator()
Return an iterator over the collection of SchedulableEntities which orders
them for container assignment
|
String |
getInfo()
Display information regarding configuration and status
|
int |
getNumSchedulableEntities()
Get the number of SchedulableEntities managed for allocation and
preemption ordering
|
Iterator<S> |
getPreemptionIterator()
Return an iterator over the collection of SchedulableEntities which orders
them for preemption
|
Collection<S> |
getSchedulableEntities()
Get the collection of SchedulableEntities which are managed by this
OrderingPolicy - should include processes returned by the Assignment and
Preemption iterator with no guarantees regarding order
|
boolean |
removeSchedulableEntity(S s)
Remove a SchedulableEntity from management for allocation and preemption
ordering
|
Collection<S> getSchedulableEntities()
Iterator<S> getAssignmentIterator()
Iterator<S> getPreemptionIterator()
void addSchedulableEntity(S s)
boolean removeSchedulableEntity(S s)
void addAllSchedulableEntities(Collection<S> sc)
int getNumSchedulableEntities()
void configure(Map<String,String> conf)
void containerAllocated(S schedulableEntity, RMContainer r)
void containerReleased(S schedulableEntity, RMContainer r)
void demandUpdated(S schedulableEntity)
String getInfo()
Copyright © 2017 Apache Software Foundation. All Rights Reserved.