-
- Downloads
[SPARK-15714][CORE] Fix flaky o.a.s.scheduler.BlacklistIntegrationSuite
## What changes were proposed in this pull request? BlacklistIntegrationSuite (introduced by SPARK-10372) is a bit flaky because of some race conditions: 1. Failed jobs might have non-empty results, because the resultHandler will be invoked for successful tasks (if there are task successes before failures) 2. taskScheduler.taskIdToTaskSetManager must be protected by a lock on taskScheduler (1) has failed a handful of jenkins builds recently. I don't think I've seen (2) in jenkins, but I've run into with some uncommitted tests I'm working on where there are lots more tasks. While I was in there, I also made an unrelated fix to `runningTasks`in the test framework -- there was a pointless `O(n)` operation to remove completed tasks, could be `O(1)`. ## How was this patch tested? I modified the o.a.s.scheduler.BlacklistIntegrationSuite to have it run the tests 1k times on my laptop. It failed 11 times before this change, and none with it. (Pretty sure all the failures were problem (1), though I didn't check all of them). Also the full suite of tests via jenkins. Author: Imran Rashid <irashid@cloudera.com> Closes #13454 from squito/SPARK-15714.
Showing
- core/src/main/scala/org/apache/spark/scheduler/TaskSchedulerImpl.scala 1 addition, 0 deletions.../scala/org/apache/spark/scheduler/TaskSchedulerImpl.scala
- core/src/test/scala/org/apache/spark/scheduler/BlacklistIntegrationSuite.scala 4 additions, 6 deletions...rg/apache/spark/scheduler/BlacklistIntegrationSuite.scala
- core/src/test/scala/org/apache/spark/scheduler/SchedulerIntegrationSuite.scala 49 additions, 19 deletions...rg/apache/spark/scheduler/SchedulerIntegrationSuite.scala
Please register or sign in to comment