Search code examples
sparkr

how to set app name for SparkR?


Does any one know how to set the application name for a SparkR job? I can not find the relevant api at all. The sample code shows the availability of spark after loading the SparkR lib.

library(SparkR)
sparkR.session()

after that you can make the spark.lapply(...) call. How do you set the app name using the spark variable?


Solution

  • The application name is set with the appName argument of sparkR.session(); from the docs:

    sparkR.session(master = "", appName = "SparkR",
      sparkHome = Sys.getenv("SPARK_HOME"), sparkConfig = list(),
      sparkJars = "", sparkPackages = "", enableHiveSupport = TRUE, ...)