We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c5414b6 commit cb8cc76Copy full SHA for cb8cc76
core/src/main/scala/org/apache/spark/util/Utils.scala
@@ -1437,7 +1437,7 @@ private[spark] object Utils extends Logging {
1437
val serviceString = if (serviceName.isEmpty) "" else s" '$serviceName'"
1438
for (offset <- 0 to maxRetries) {
1439
// Do not increment port if startPort is 0, which is treated as a special port
1440
- val tryPort = if (startPort == 0) startPort else (startPort + offset) % 65536
+ val tryPort = if (startPort == 0) startPort else (startPort + offset) % (65536 - 1024) + 1024
1441
try {
1442
val (service, port) = startService(tryPort)
1443
logInfo(s"Successfully started service$serviceString on port $port.")
0 commit comments