cloud-fan commented on code in PR #43926:
URL: https://github.com/apache/spark/pull/43926#discussion_r1400176679
##########
core/src/test/scala/org/apache/spark/JobCancellationSuite.scala:
##########
@@ -153,6 +153,91 @@ class JobCancellationSuite extends SparkFunSuite with
Matchers with BeforeAndAft
assert(jobB.get() === 100)
}
+ test("if cancel job group and future jobs, skip running jobs in the same job
group") {
+ sc = new SparkContext("local[2]", "test")
+
+ val sem = new Semaphore(0)
+ sc.addSparkListener(new SparkListener {
+ override def onJobStart(jobStart: SparkListenerJobStart): Unit = {
+ sem.release()
+ }
+ })
+
+ val jobGroupName = "job-group"
+
+ val jobA = Future {
Review Comment:
why do we run this job in a separated thread?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]