[
https://issues.apache.org/jira/browse/YARN-4846?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15250717#comment-15250717
]
Wangda Tan commented on YARN-4846:
----------------------------------
[~bibinchundatt],
bq. For issue 2 One probable cause could be editSchedule() is getting invoked
by SchedulingMonitor at the same time editSchedule() is called from testcase.
That's possible, we can add synchronized modifier to editSchedule to avoid such
thing happens, and we can set the PREEMPTION_MONITORING_INTERVAL to a large
value to avoid it runs during tests.
I attached a preliminary patch to fix the issue, it uses "<=" for kill
container check, and uses "<" for staled container check. In addition, the
patch adds a batch timestamp for selected candidates as well as checking for
kill/staled containers. Does it sound reasonable to you?
> Random failures for
> TestCapacitySchedulerPreemption#testPreemptionPolicyShouldRespectAlreadyMarkedKillableContainers
> --------------------------------------------------------------------------------------------------------------------
>
> Key: YARN-4846
> URL: https://issues.apache.org/jira/browse/YARN-4846
> Project: Hadoop YARN
> Issue Type: Sub-task
> Reporter: Bibin A Chundatt
> Assignee: Bibin A Chundatt
> Attachments: 0001-YARN-4846.patch, 0002-YARN-4846.patch,
> YARN-4846-update-PCPP.patch
>
>
> {noformat}
> java.lang.AssertionError: expected:<1> but was:<0>
> at org.junit.Assert.fail(Assert.java:88)
> at org.junit.Assert.failNotEquals(Assert.java:743)
> at org.junit.Assert.assertEquals(Assert.java:118)
> at org.junit.Assert.assertEquals(Assert.java:555)
> at org.junit.Assert.assertEquals(Assert.java:542)
> at
> org.apache.hadoop.yarn.server.resourcemanager.scheduler.capacity.TestCapacitySchedulerPreemption.testPreemptionPolicyShouldRespectAlreadyMarkedKillableContainers(TestCapacitySchedulerPreemption.java:473)
> {noformat}
> https://builds.apache.org/job/PreCommit-YARN-Build/10826/testReport/org.apache.hadoop.yarn.server.resourcemanager.scheduler.capacity/TestCapacitySchedulerPreemption/testPreemptionPolicyShouldRespectAlreadyMarkedKillableContainers/
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)