sparknlp
!!!
@JakeRuss I'm trying to connect to remote cassandra using host, port, user name and password
conf <- spark_config()
conf[["spark.cassandra.connection.ssl.enabled"]] = TRUE
conf[["spark.cassandra.connection.host"]] = cassandra_host
conf[["spark.cassandra.connection.port"]] = cassandra_port
conf[["spark.cassandra.auth.username"]] = cassandra_username
conf[["spark.cassandra.auth.password"]] = cassandra_password
config[["sparklyr.defaultPackages"]] <- c("org.apache.hadoop:hadoop-aws:2.7.3", "datastax:spark-cassandra-connector:2.0.0-RC1-s_2.11")
sc <- spark_connect(master = "local", version = "2.2.0", spark_home = spark_path, config = conf)
df <- spark_read_source(
sc,
name = "emp",
source = "org.apache.spark.sql.cassandra",
options = list(keyspace = "temp", table = "category_distribution"),
memory = FALSE)
but this is not working. please suggest a solution
Error in force(code) :
Failed while connecting to sparklyr to port (8880) for sessionid (52016): Gateway in localhost:8880 did not respond.
Path: C:\Users\Tarun_Gupta2\AppData\Local\spark\spark-2.4.5-bin-hadoop2.7\bin\spark-submit2.cmd
Parameters: --class, sparklyr.Shell, "C:\Users\TarunGupta2\Documents\R\win-library\3.6\sparklyr\java\sparklyr-2.4-2.11.jar", 8880, 52016
Log: C:\Users\TARUN~1\AppData\Local\Temp\Rtmpw9ZV82\filea70487da97_spark.log
---- Output Log ----
/Java/jdk1.8.0_251\bin\java was unexpected at this time.
---- Error Log ----
Hi , Someone please help me to fix the below error ,I have another setup working which is hadoop 2 (EMR 5.x) , Now I am testing EMR 6 with new spark home that is /usr/lib/spark6/ , Just I compare with both setting everything looks good for me. Is there any specific setting I need to checlk
sc <- spark_connect(master = "yarn", spark_home = "/usr/lib/spark6", deploymode = "cluster", enableHiveSupport = TRUE)
Error in force(code) :
Failed while connecting to sparklyr to port (8880) for sessionid (32486): Gateway in localhost:8880 did not respond.
Path: /usr/lib/spark6/bin/spark-submit
Parameters: --class, sparklyr.Shell, '/opt/R/3.6.0/lib64/R/library/sparklyr/java/sparklyr-2.4-2.11.jar', 8880, 32486
Log: /tmp/RtmpijZOtA/filee69e18f188dc_spark.log
---- Output Log ----
Exception in thread "main" java.lang.NoSuchMethodError: scala.Predef$.refArrayOps([Ljava/lang/Object;)Lscala/collection/mutable/ArrayOps;
at sparklyr.Shell$.main(shell.scala:9)
at sparklyr.Shell.main(shell.scala)
GOOGLE_CITY_DESC
' given input columns:"compute()
forces the SQL query you have accumulated so far to be evaluated so that might help
@njesp You can try the following to print spark-submit log to console to see what's failing:
library(sparklyr)
options(sparklyr.log.console = TRUE)
sc <- spark_connect(master = "local")
The spark-submit log usually ends up in a text file, but the path to that file is highly system-dependent and also could be influenced by your local config... so rather than spending time figuring out where it might be it's just easier to have options(sparklyr.log.console = TRUE) while trouble-shooting