org.apache.hadoop.mapreduce.v2.app.rm
Class RMContainerAllocator
java.lang.Object
org.apache.hadoop.yarn.service.AbstractService
org.apache.hadoop.mapreduce.v2.app.rm.RMCommunicator
org.apache.hadoop.mapreduce.v2.app.rm.RMContainerRequestor
org.apache.hadoop.mapreduce.v2.app.rm.RMContainerAllocator
- All Implemented Interfaces:
- ContainerAllocator, org.apache.hadoop.yarn.event.EventHandler<ContainerAllocatorEvent>, org.apache.hadoop.yarn.service.Service
public class RMContainerAllocator
- extends RMContainerRequestor
- implements ContainerAllocator
Allocates the container from the ResourceManager scheduler.
| Nested classes/interfaces inherited from interface org.apache.hadoop.yarn.service.Service |
org.apache.hadoop.yarn.service.Service.STATE |
|
Method Summary |
boolean |
getIsReduceStarted()
|
int |
getMemLimit()
|
void |
handle(ContainerAllocatorEvent event)
|
protected void |
handleEvent(ContainerAllocatorEvent event)
|
protected void |
heartbeat()
|
void |
init(org.apache.hadoop.conf.Configuration conf)
|
void |
rampDownReduces(int rampDown)
|
void |
rampUpReduces(int rampUp)
|
void |
scheduleAllReduces()
|
void |
scheduleReduces(int totalMaps,
int completedMaps,
int scheduledMaps,
int scheduledReduces,
int assignedMaps,
int assignedReduces,
int mapResourceReqt,
int reduceResourceReqt,
int numPendingReduces,
float maxReduceRampupLimit,
float reduceSlowStart)
|
void |
setIsReduceStarted(boolean reduceStarted)
|
void |
start()
|
void |
stop()
|
| Methods inherited from class org.apache.hadoop.mapreduce.v2.app.rm.RMCommunicator |
createSchedulerProxy, getApplicationProgress, getContext, getJob, getMaxContainerCapability, getMinContainerCapability, register, setShouldUnregister, setSignalled, startAllocatorThread, unregister |
| Methods inherited from class org.apache.hadoop.yarn.service.AbstractService |
getConfig, getName, getServiceState, getStartTime, register, unregister |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DEFAULT_COMPLETED_MAPS_PERCENT_FOR_REDUCE_SLOWSTART
public static final float DEFAULT_COMPLETED_MAPS_PERCENT_FOR_REDUCE_SLOWSTART
- See Also:
- Constant Field Values
RMContainerAllocator
public RMContainerAllocator(ClientService clientService,
AppContext context)
init
public void init(org.apache.hadoop.conf.Configuration conf)
- Specified by:
init in interface org.apache.hadoop.yarn.service.Service- Overrides:
init in class RMContainerRequestor
start
public void start()
- Specified by:
start in interface org.apache.hadoop.yarn.service.Service- Overrides:
start in class RMCommunicator
heartbeat
protected void heartbeat()
throws Exception
- Specified by:
heartbeat in class RMCommunicator
- Throws:
Exception
stop
public void stop()
- Specified by:
stop in interface org.apache.hadoop.yarn.service.Service- Overrides:
stop in class RMCommunicator
getIsReduceStarted
public boolean getIsReduceStarted()
setIsReduceStarted
public void setIsReduceStarted(boolean reduceStarted)
handle
public void handle(ContainerAllocatorEvent event)
- Specified by:
handle in interface org.apache.hadoop.yarn.event.EventHandler<ContainerAllocatorEvent>
handleEvent
protected void handleEvent(ContainerAllocatorEvent event)
scheduleReduces
@InterfaceAudience.Private
public void scheduleReduces(int totalMaps,
int completedMaps,
int scheduledMaps,
int scheduledReduces,
int assignedMaps,
int assignedReduces,
int mapResourceReqt,
int reduceResourceReqt,
int numPendingReduces,
float maxReduceRampupLimit,
float reduceSlowStart)
scheduleAllReduces
@InterfaceAudience.Private
public void scheduleAllReduces()
rampUpReduces
@InterfaceAudience.Private
public void rampUpReduces(int rampUp)
rampDownReduces
@InterfaceAudience.Private
public void rampDownReduces(int rampDown)
getMemLimit
@InterfaceAudience.Private
public int getMemLimit()
Copyright © 2012 Apache Software Foundation. All Rights Reserved.