Skip to content

Commit

Permalink
qualify utils class for livy
Browse files Browse the repository at this point in the history
  • Loading branch information
javierluraschi committed Oct 19, 2018
1 parent ebae3bb commit 115f29f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion java/spark-1.5.2/backend.scala
Expand Up @@ -168,7 +168,7 @@ class Backend() {
logger = new Logger("Backend", sessionId)
if (isWorker) logger = new Logger("Worker", sessionId)

val newPort = Utils.nextPort(port, inetAddress)
val newPort = sparklyr.Utils.nextPort(port, inetAddress)
logger.log("found port " + newPort + " is available")

gatewayServerSocket = new ServerSocket(newPort, 1, inetAddress)
Expand Down
4 changes: 2 additions & 2 deletions java/spark-1.5.2/channel.scala
Expand Up @@ -36,13 +36,13 @@ class BackendChannel(logger: Logger, terminate: () => Unit, serializer: Serializ
val anyIpAddress = Array[Byte](0, 0, 0, 0)
val anyInetAddress = InetAddress.getByAddress(anyIpAddress)

val channelPort = if (deterministicPort) Utils.nextPort(port, anyInetAddress) else 0
val channelPort = if (deterministicPort) sparklyr.Utils.nextPort(port, anyInetAddress) else 0
logger.log("is using port " + channelPort + " for backend channel")

inetAddress = new InetSocketAddress(anyInetAddress, channelPort)
}
else {
val channelPort = if (deterministicPort) Utils.nextPort(port, InetAddress.getLoopbackAddress()) else 0
val channelPort = if (deterministicPort) sparklyr.Utils.nextPort(port, InetAddress.getLoopbackAddress()) else 0
logger.log("is using port " + channelPort + " for backend channel")

inetAddress = new InetSocketAddress(InetAddress.getLoopbackAddress(), channelPort)
Expand Down

0 comments on commit 115f29f

Please sign in to comment.