Skip to content
This repository has been archived by the owner on Nov 30, 2019. It is now read-only.

Commit

Permalink
in AM create a new actorSystem
Browse files Browse the repository at this point in the history
  • Loading branch information
lianhuiwang committed Jan 9, 2015
1 parent 2164ea8 commit 7d33791
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -245,12 +245,14 @@ private[spark] class ApplicationMaster(args: ApplicationMasterArguments,
ApplicationMaster.EXIT_SC_NOT_INITED,
"Timed out waiting for SparkContext.")
} else {
actorSystem = AkkaUtils.createActorSystem("sparkYarnAM", Utils.localHostName, 0,
conf = sparkConf, securityManager = securityMgr)._1
val driverUrl = "akka.tcp://%s@%s:%s/user/%s".format(
SparkEnv.driverActorSystemName,
sc.getConf.get("spark.driver.host"),
sc.getConf.get("spark.driver.port"),
YarnSchedulerBackend.ACTOR_NAME)
actor = sc.env.actorSystem.actorOf(Props(new AMActor(driverUrl, true)), name = "YarnAM")
actor = actorSystem.actorOf(Props(new AMActor(driverUrl, true)), name = "YarnAM")
registerAM(sc.ui.map(_.appUIAddress).getOrElse(""), securityMgr)
userClassThread.join()
}
Expand Down

0 comments on commit 7d33791

Please sign in to comment.