Github user JoshRosen commented on a diff in the pull request:
https://github.com/apache/spark/pull/3571#discussion_r23138526
--- Diff: core/src/main/scala/org/apache/spark/util/AkkaUtils.scala ---
@@ -228,9 +230,22 @@ private[spark] object AkkaUtils extends Logging {
actorSystem: ActorSystem): ActorRef = {
val executorActorSystemName = SparkEnv.executorActorSystemName
Utils.checkHost(host, "Expected hostname")
- val url = s"akka.tcp://$executorActorSystemName@$host:$port/user/$name"
+ val url = address(executorActorSystemName, host, port, name, conf)
val timeout = AkkaUtils.lookupTimeout(conf)
logInfo(s"Connecting to $name: $url")
Await.result(actorSystem.actorSelection(url).resolveOne(timeout),
timeout)
}
+
+ def protocol(conf: SparkConf): String = {
+ if (conf.getBoolean("spark.ssl.enabled", defaultValue = false)) {
+ "akka.ssl.tcp"
+ } else {
+ "akka.tcp"
+ }
+ }
+
+ def address(systemName: String, host: String, port: Any, actorName:
String,
--- End diff --
Minor style issue: if the arguments won't fit on one line, then wrap them
one per line, e.g.
```
def address(
systemName: String,
host: String,
[...]
```
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]