Skip to content

Commit 2fedb5d

Browse files
scwfpwendell
authored andcommitted
[SPARK-3756] [Core]check exception is caused by an address-port collision properly
Jetty server use MultiException to handle exceptions when start server refer https://github.com/eclipse/jetty.project/blob/jetty-8.1.14.v20131031/jetty-server/src/main/java/org/eclipse/jetty/server/Server.java So in ```isBindCollision``` add the logical to cover MultiException Author: scwf <[email protected]> Closes #2611 from scwf/fix-isBindCollision and squashes the following commits: 984cb12 [scwf] optimize the fix 3a6c849 [scwf] fix bug in isBindCollision
1 parent 6390aae commit 2fedb5d

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

core/src/main/scala/org/apache/spark/util/Utils.scala

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ import java.nio.ByteBuffer
2323
import java.util.{Properties, Locale, Random, UUID}
2424
import java.util.concurrent.{ThreadFactory, ConcurrentHashMap, Executors, ThreadPoolExecutor}
2525

26+
import org.eclipse.jetty.util.MultiException
27+
2628
import scala.collection.JavaConversions._
2729
import scala.collection.Map
2830
import scala.collection.mutable.ArrayBuffer
@@ -1470,6 +1472,7 @@ private[spark] object Utils extends Logging {
14701472
return true
14711473
}
14721474
isBindCollision(e.getCause)
1475+
case e: MultiException => e.getThrowables.exists(isBindCollision)
14731476
case e: Exception => isBindCollision(e.getCause)
14741477
case _ => false
14751478
}

0 commit comments

Comments
 (0)