Skip to content

Commit 363f3bb

Browse files
committed
Fix test in PythonRDDSuite
1 parent ef137b6 commit 363f3bb

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

core/src/main/scala/org/apache/spark/security/SocketAuthHelper.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ import org.apache.spark.util.Utils
3434
*
3535
* There's no secrecy, so this relies on the sockets being either local or somehow encrypted.
3636
*/
37-
private[spark] class SocketAuthHelper(conf: SparkConf) {
37+
private[spark] class SocketAuthHelper(val conf: SparkConf) {
3838

3939
val secret = Utils.createSecret(conf)
4040

core/src/main/scala/org/apache/spark/security/SocketAuthServer.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ private[spark] abstract class SocketAuthServer[T](
5151
logTrace("Creating listening socket")
5252
val serverSocket = new ServerSocket(0, 1, InetAddress.getByAddress(Array(127, 0, 0, 1)))
5353
// Close the socket if no connection in the configured seconds
54-
val timeout = SparkEnv.get.conf.get(PYTHON_AUTH_SOCKET_TIMEOUT).toInt
54+
val timeout = authHelper.conf.get(PYTHON_AUTH_SOCKET_TIMEOUT).toInt
5555
logTrace(s"Setting timeout to $timeout sec")
5656
serverSocket.setSoTimeout(timeout * 1000)
5757

0 commit comments

Comments
 (0)