-
- Downloads
[SPARK-16184][SPARKR] conf API for SparkSession
## What changes were proposed in this pull request? Add `conf` method to get Runtime Config from SparkSession ## How was this patch tested? unit tests, manual tests This is how it works in sparkR shell: ``` SparkSession available as 'spark'. > conf() $hive.metastore.warehouse.dir [1] "file:/opt/spark-2.0.0-bin-hadoop2.6/R/spark-warehouse" $spark.app.id [1] "local-1466749575523" $spark.app.name [1] "SparkR" $spark.driver.host [1] "10.0.2.1" $spark.driver.port [1] "45629" $spark.executorEnv.LD_LIBRARY_PATH [1] "$LD_LIBRARY_PATH:/usr/lib/R/lib:/usr/lib/x86_64-linux-gnu:/usr/lib/jvm/default-java/jre/lib/amd64/server" $spark.executor.id [1] "driver" $spark.home [1] "/opt/spark-2.0.0-bin-hadoop2.6" $spark.master [1] "local[*]" $spark.sql.catalogImplementation [1] "hive" $spark.submit.deployMode [1] "client" > conf("spark.master") $spark.master [1] "local[*]" ``` Author: Felix Cheung <felixcheung_m@hotmail.com> Closes #13885 from felixcheung/rconf.
Showing
- R/pkg/NAMESPACE 1 addition, 0 deletionsR/pkg/NAMESPACE
- R/pkg/R/SQLContext.R 46 additions, 4 deletionsR/pkg/R/SQLContext.R
- R/pkg/inst/tests/testthat/test_sparkSQL.R 6 additions, 6 deletionsR/pkg/inst/tests/testthat/test_sparkSQL.R
- sql/core/src/main/scala/org/apache/spark/sql/api/r/SQLUtils.scala 4 additions, 0 deletions.../src/main/scala/org/apache/spark/sql/api/r/SQLUtils.scala
Loading
Please register or sign in to comment