[
https://issues.apache.org/jira/browse/YARN-8292?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16479599#comment-16479599
]
Eric Payne commented on YARN-8292:
----------------------------------
Thanks for the updated patch, [~leftnoteasy].
The changes seem to be over-preempting. In the unit test, the request is for 1
of each resource type, but it is preempting 2 containers.
{code:java|title=test3ResourceTypesInterQueuePreemption}
...
String queuesConfig =
// guaranteed,max,used,pending
"root(=[30:18:6 30:18:6 12:12:6 1:1:1]);" + //root
"-a(=[10:6:2 10:6:2 6:6:3 0:0:0]);" + // a
"-b(=[10:6:2 10:6:2 6:6:3 0:0:0]);" + // b
"-c(=[10:6:2 10:6:2 0:0:0 1:1:1])"; // c
...
verify(mDisp, times(1)).handle(
argThat(new
TestProportionalCapacityPreemptionPolicy.IsPreemptionRequestFor(getAppAttemptId(1))));
{code}
NOTE: if I add the following check to verify that a container was not preempted
from app2, it fails:
{code:java}
verify(mDisp, times(0)).handle(
argThat(new
TestProportionalCapacityPreemptionPolicy.IsPreemptionRequestFor(getAppAttemptId(2))));
{code}
Since the resource request is {{<1,1,1>}}, I would expect only 1 container to
be preempted. However, in the unit test logs, I see the following:
{code:java}
2018-05-17 19:01:00,372 DEBUG [main]
capacity.ProportionalCapacityPreemptionPolicy
(ProportionalCapacityPreemptionPolicy.java:preemptOrkillSelectedContainerAfterWait(314))
- Starting to preempt containers for selectedCandidates and size:2
{code}
> Fix the dominant resource preemption cannot happen when some of the resource
> vector becomes negative
> ----------------------------------------------------------------------------------------------------
>
> Key: YARN-8292
> URL: https://issues.apache.org/jira/browse/YARN-8292
> Project: Hadoop YARN
> Issue Type: Bug
> Components: yarn
> Reporter: Sumana Sathish
> Assignee: Wangda Tan
> Priority: Critical
> Attachments: YARN-8292.001.patch, YARN-8292.002.patch,
> YARN-8292.003.patch
>
>
> This is an example of the problem:
>
> {code}
> // guaranteed, max, used, pending
> "root(=[30:18:6 30:18:6 12:12:6 1:1:1]);" + //root
> "-a(=[10:6:2 10:6:2 6:6:3 0:0:0]);" + // a
> "-b(=[10:6:2 10:6:2 6:6:3 0:0:0]);" + // b
> "-c(=[10:6:2 10:6:2 0:0:0 1:1:1])"; // c
> {code}
> There're 3 resource types. Total resource of the cluster is 30:18:6
> For both of a/b, there're 3 containers running, each of container is 2:2:1.
> Queue c uses 0 resource, and have 1:1:1 pending resource.
> Under existing logic, preemption cannot happen.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]