[
https://issues.apache.org/jira/browse/YARN-4026?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14687398#comment-14687398
]
Jian He commented on YARN-4026:
-------------------------------
- why "assignment.setFulfilledReservation(true);" is called in Reserved state ?
{code}
if (result.getAllocationState() == AllocationState.RESERVED) {
// This is a reserved container
LOG.info("Reserved container " + " application="
+ application.getApplicationId() + " resource=" + allocatedResource
+ " queue=" + this.toString() + " cluster=" + clusterResource);
assignment.getAssignmentInformation().addReservationDetails(
updatedContainer.getId(),
application.getCSLeafQueue().getQueuePath());
assignment.getAssignmentInformation().incrReservations();
Resources.addTo(assignment.getAssignmentInformation().getReserved(),
allocatedResource);
assignment.setFulfilledReservation(true);
} else {
{code}
- I think here can always return ContainerAllocation.LOCALITY_SKIPPED as the
semantics of this method is to try to allocate a container for certain
locality.
{code}
return type == NodeType.OFF_SWITCH ? ContainerAllocation.APP_SKIPPED
: ContainerAllocation.LOCALITY_SKIPPED;
{code}
The caller here can choose to return APP_SKIPPED if it sees the LOCALITY_SKIPPED
{code}
assigned =
assignOffSwitchContainers(clusterResource, offSwitchResourceRequest,
node, priority, reservedContainer, schedulingMode,
currentResoureLimits);
assigned.requestNodeType = requestType;
return assigned;
}
{code}
> FiCaSchedulerApp: ContainerAllocator should be able to choose how to order
> pending resource requests
> ----------------------------------------------------------------------------------------------------
>
> Key: YARN-4026
> URL: https://issues.apache.org/jira/browse/YARN-4026
> Project: Hadoop YARN
> Issue Type: Bug
> Reporter: Wangda Tan
> Assignee: Wangda Tan
> Attachments: YARN-4026.1.patch
>
>
> After YARN-3983, we have an extensible ContainerAllocator which can be used
> by FiCaSchedulerApp to decide how to allocate resources.
> While working on YARN-1651 (allocate resource to increase container), I found
> one thing in existing logic not flexible enough:
> - ContainerAllocator decides what to allocate for a given node and priority:
> To support different kinds of resource allocation, for example, priority as
> weight / skip priority or not, etc. It's better to let ContainerAllocator to
> choose how to order pending resource requests.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)