[ https://issues.apache.org/jira/browse/SPARK-31845?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
jiaan.geng updated SPARK-31845: ------------------------------- Description: DAGSchedulerSuite provides completeNextStageWithFetchFailure to make next stage occurs fetch failure. But many test case uses complete directly as follows: {code:java} complete(taskSets(2), Seq( (FetchFailed(BlockManagerId("hostA-exec2", "hostA", 12345), firstShuffleId, 0L, 0, 0, "ignored"), null) )) {code} We need to improve completeNextStageWithFetchFailure and reuse it. DAGSchedulerSuite also check the results show below: {code:java} complete(taskSets(0), Seq((Success, 42))) assert(results === Map(0 -> 42)) {code} We can extract this as checkAnswer in common was: DAGSchedulerSuite provides completeNextStageWithFetchFailure to make next stage occurs fetch failure. But many test case uses complete directly as follows: {code:java} complete(taskSets(2), Seq( (FetchFailed(BlockManagerId("hostA-exec2", "hostA", 12345), firstShuffleId, 0L, 0, 0, "ignored"), null) )) {code} We need to improve completeNextStageWithFetchFailure and reuse it. > DAGSchedulerSuite: Reuse completeNextStageWithFetchFailure and support > checkAnswer > ---------------------------------------------------------------------------------- > > Key: SPARK-31845 > URL: https://issues.apache.org/jira/browse/SPARK-31845 > Project: Spark > Issue Type: Sub-task > Components: Spark Core > Affects Versions: 3.1.0 > Reporter: jiaan.geng > Priority: Major > > DAGSchedulerSuite provides completeNextStageWithFetchFailure to make next > stage occurs fetch failure. > But many test case uses complete directly as follows: > {code:java} > complete(taskSets(2), Seq( > (FetchFailed(BlockManagerId("hostA-exec2", "hostA", 12345), > firstShuffleId, 0L, 0, 0, "ignored"), > null) > )) > {code} > We need to improve completeNextStageWithFetchFailure and reuse it. > DAGSchedulerSuite also check the results show below: > {code:java} > complete(taskSets(0), Seq((Success, 42))) > assert(results === Map(0 -> 42)) > {code} > We can extract this as checkAnswer in common -- This message was sent by Atlassian Jira (v8.3.4#803005) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org For additional commands, e-mail: issues-h...@spark.apache.org