Class RUtils

Object
org.apache.spark.api.r.RUtils

public class RUtils extends Object
  • Constructor Details

    • RUtils

      public RUtils()
  • Method Details

    • rPackages

      public static scala.Option<String> rPackages()
    • localSparkRPackagePath

      public static scala.Option<String> localSparkRPackagePath()
      Get the SparkR package path in the local spark distribution.
      Returns:
      (undocumented)
    • isSparkRInstalled

      public static boolean isSparkRInstalled()
      Check if SparkR is installed before running tests that use SparkR.
      Returns:
      (undocumented)
    • sparkRPackagePath

      public static scala.collection.Seq<String> sparkRPackagePath(boolean isDriver)
      Get the list of paths for R packages in various deployment modes, of which the first path is for the SparkR package itself. The second path is for R packages built as part of Spark Packages, if any exist. Spark Packages can be provided through the "--packages" or "--jars" command line options.

      This assumes that Spark properties spark.master and spark.submit.deployMode and environment variable SPARK_HOME are set.

      Parameters:
      isDriver - (undocumented)
      Returns:
      (undocumented)
    • isRInstalled

      public static boolean isRInstalled()
      Check if R is installed before running tests that use R commands.
    • isEncryptionEnabled

      public static boolean isEncryptionEnabled(JavaSparkContext sc)
    • getJobTags

      public static String[] getJobTags(JavaSparkContext sc)