@InterfaceAudience.Public @InterfaceStability.Stable public abstract class AllocateRequest extends Object
The core request sent by the ApplicationMaster
to the
ResourceManager
to obtain resources in the cluster.
The request includes:
ResourceRequest
to inform the
ResourceManager
about the application's
resource requirements.
Container
which are being returned.
UpdateContainerRequest
to inform
the ResourceManager
about the change in
requirements of running containers.
Modifier and Type | Class and Description |
---|---|
static class |
AllocateRequest.AllocateRequestBuilder
Class to construct instances of
AllocateRequest with specific
options. |
Constructor and Description |
---|
AllocateRequest() |
Modifier and Type | Method and Description |
---|---|
abstract List<ResourceRequest> |
getAskList()
Get the list of
ResourceRequest to update the
ResourceManager about the application's resource requirements. |
abstract float |
getProgress()
Get the current progress of application.
|
abstract List<ContainerId> |
getReleaseList()
Get the list of
ContainerId of containers being
released by the ApplicationMaster . |
abstract ResourceBlacklistRequest |
getResourceBlacklistRequest()
Get the
ResourceBlacklistRequest being sent by the
ApplicationMaster . |
abstract int |
getResponseId()
Get the response id used to track duplicate responses.
|
List<SchedulingRequest> |
getSchedulingRequests()
Get the list of Scheduling requests being sent by the
ApplicationMaster . |
abstract String |
getTrackingUrl()
Get the tracking url update for this heartbeat.
|
abstract List<UpdateContainerRequest> |
getUpdateRequests()
Get the list of container update requests being sent by the
ApplicationMaster . |
static AllocateRequest.AllocateRequestBuilder |
newBuilder() |
static AllocateRequest |
newInstance(int responseID,
float appProgress,
List<ResourceRequest> resourceAsk,
List<ContainerId> containersToBeReleased,
List<UpdateContainerRequest> updateRequests,
ResourceBlacklistRequest resourceBlacklistRequest) |
static AllocateRequest |
newInstance(int responseID,
float appProgress,
List<ResourceRequest> resourceAsk,
List<ContainerId> containersToBeReleased,
ResourceBlacklistRequest resourceBlacklistRequest) |
static AllocateRequest |
newInstance(int responseID,
float appProgress,
List<ResourceRequest> resourceAsk,
List<ContainerId> containersToBeReleased,
ResourceBlacklistRequest resourceBlacklistRequest,
String trackingUrl) |
abstract void |
setAskList(List<ResourceRequest> resourceRequests)
Set list of
ResourceRequest to update the
ResourceManager about the application's resource requirements. |
abstract void |
setProgress(float progress)
Set the current progress of application
|
abstract void |
setReleaseList(List<ContainerId> releaseContainers)
Set the list of
ContainerId of containers being
released by the ApplicationMaster |
abstract void |
setResourceBlacklistRequest(ResourceBlacklistRequest resourceBlacklistRequest)
Set the
ResourceBlacklistRequest to inform the
ResourceManager about the blacklist additions and removals
per the ApplicationMaster . |
abstract void |
setResponseId(int id)
Set the response id used to track duplicate responses.
|
void |
setSchedulingRequests(List<SchedulingRequest> schedulingRequests)
Set the list of Scheduling requests to inform the
ResourceManager about the application's resource requirements
(potentially including allocation tags and placement constraints). |
abstract void |
setTrackingUrl(String trackingUrl)
Set the new tracking url for this application.
|
abstract void |
setUpdateRequests(List<UpdateContainerRequest> updateRequests)
Set the list of container update requests to inform the
ResourceManager about the containers that need to be
updated. |
@InterfaceAudience.Public @InterfaceStability.Stable public static AllocateRequest newInstance(int responseID, float appProgress, List<ResourceRequest> resourceAsk, List<ContainerId> containersToBeReleased, ResourceBlacklistRequest resourceBlacklistRequest)
@InterfaceAudience.Public @InterfaceStability.Unstable public static AllocateRequest newInstance(int responseID, float appProgress, List<ResourceRequest> resourceAsk, List<ContainerId> containersToBeReleased, ResourceBlacklistRequest resourceBlacklistRequest, String trackingUrl)
@InterfaceAudience.Public @InterfaceStability.Unstable public static AllocateRequest newInstance(int responseID, float appProgress, List<ResourceRequest> resourceAsk, List<ContainerId> containersToBeReleased, List<UpdateContainerRequest> updateRequests, ResourceBlacklistRequest resourceBlacklistRequest)
@InterfaceAudience.Public @InterfaceStability.Stable public abstract int getResponseId()
@InterfaceAudience.Public @InterfaceStability.Stable public abstract void setResponseId(int id)
id
- response id@InterfaceAudience.Public @InterfaceStability.Stable public abstract float getProgress()
@InterfaceAudience.Public @InterfaceStability.Stable public abstract void setProgress(float progress)
progress
- current progress of application@InterfaceAudience.Public @InterfaceStability.Stable public abstract List<ResourceRequest> getAskList()
ResourceRequest
to update the
ResourceManager
about the application's resource requirements.ResourceRequest
ResourceRequest
@InterfaceAudience.Public @InterfaceStability.Stable public abstract void setAskList(List<ResourceRequest> resourceRequests)
ResourceRequest
to update the
ResourceManager
about the application's resource requirements.resourceRequests
- list of ResourceRequest
to update the
ResourceManager
about the application's
resource requirementsResourceRequest
@InterfaceAudience.Public @InterfaceStability.Stable public abstract List<ContainerId> getReleaseList()
ContainerId
of containers being
released by the ApplicationMaster
.ContainerId
of containers being
released by the ApplicationMaster
@InterfaceAudience.Public @InterfaceStability.Stable public abstract void setReleaseList(List<ContainerId> releaseContainers)
ContainerId
of containers being
released by the ApplicationMaster
releaseContainers
- list of ContainerId
of
containers being released by the
ApplicationMaster
@InterfaceAudience.Public @InterfaceStability.Stable public abstract ResourceBlacklistRequest getResourceBlacklistRequest()
ResourceBlacklistRequest
being sent by the
ApplicationMaster
.ResourceBlacklistRequest
being sent by the
ApplicationMaster
ResourceBlacklistRequest
@InterfaceAudience.Public @InterfaceStability.Stable public abstract void setResourceBlacklistRequest(ResourceBlacklistRequest resourceBlacklistRequest)
ResourceBlacklistRequest
to inform the
ResourceManager
about the blacklist additions and removals
per the ApplicationMaster
.resourceBlacklistRequest
- the ResourceBlacklistRequest
to inform the ResourceManager
about
the blacklist additions and removals
per the ApplicationMaster
ResourceBlacklistRequest
@InterfaceAudience.Public @InterfaceStability.Unstable public abstract List<UpdateContainerRequest> getUpdateRequests()
ApplicationMaster
.UpdateContainerRequest
being sent by the
ApplicationMaster
.@InterfaceAudience.Public @InterfaceStability.Unstable public abstract void setUpdateRequests(List<UpdateContainerRequest> updateRequests)
ResourceManager
about the containers that need to be
updated.updateRequests
- list of UpdateContainerRequest
for
containers to be updated@InterfaceAudience.Public @InterfaceStability.Unstable public List<SchedulingRequest> getSchedulingRequests()
ApplicationMaster
.SchedulingRequest
being sent by the
ApplicationMaster
.@InterfaceAudience.Public @InterfaceStability.Unstable public void setSchedulingRequests(List<SchedulingRequest> schedulingRequests)
ResourceManager
about the application's resource requirements
(potentially including allocation tags and placement constraints).schedulingRequests
- list of SchedulingRequest
to update
the ResourceManager
about the application's resource
requirements.@InterfaceAudience.Public @InterfaceStability.Unstable public abstract String getTrackingUrl()
@InterfaceAudience.Public @InterfaceStability.Unstable public abstract void setTrackingUrl(String trackingUrl)
trackingUrl
- the new tracking url@InterfaceAudience.Public @InterfaceStability.Unstable public static AllocateRequest.AllocateRequestBuilder newBuilder()
Copyright © 2019 Apache Software Foundation. All rights reserved.