scala - SparkConf not found running spark neo4j connector example -
i execute spark neo4j example code so:
spark-shell --conf spark.neo4j.bolt.password=testneo4j --packages neo4j-contrib:neo4j-spark-connector:1.0.0-rc1,graphframes:graphframes:0.1.0-spark1.6 -i neo4jspark.scala my scalafile:
import org.neo4j.spark._ import org.apache.spark.sparkcontext import org.apache.spark.sparkcontext._ import org.apache.spark.rdd.rdd import org.apache.spark.streaming._ import org.apache.spark.streaming.streamingcontext._ import org.apache.spark.sparkconf val conf = new sparkconf.setmaster("local").setappname("neo4jspark") val sc = new sparkcontext(conf) val neo = neo4j(sc) val rdd = neo.cypher("match (p:point) return p").loadrowrdd rdd.count the error:
loading neo4jspark.scala... import org.neo4j.spark._ import org.apache.spark.sparkcontext import org.apache.spark.sparkcontext._ import org.apache.spark.rdd.rdd import org.apache.spark.streaming._ import org.apache.spark.streaming.streamingcontext._ import org.apache.spark.sparkconf <console>:38: error: not found: value sparkconf val conf = new sparkconf.setmaster("local").setappname("neo4jspark") ^ <console>:38: error: not found: value conf val sc = new sparkcontext(conf) ^ <console>:39: error: not found: value neo4j val neo = neo4j(sc) ^ <console>:38: error: not found: value neo val rdd = neo.cypher("match (p:point) return p").loadrowrdd ^ <console>:39: error: object count not member of package org.apache.spark.streaming.rdd rdd.count ^ i importing sparkconf, no idea whay says there no value that, missing (simple hope)??
edit: seems version error:
i ran start up:
spark-shell --conf spark.neo4j.bolt.password=testneo4j --packages neo4j-contrib:neo4j-spark-connector:2.0.0-m2,graphframes:graphframes:0.2.0-spark2.0-s_2.11 -i neo4jspark.scala still conf error run. need figure out why returned rdd breaks :d on mac, tested same versions of on windows , breaks showed because couldn't import.org.neo4j.spark._ here error:
<console>:23: error: object neo4j not member of package org import org.neo4j.spark._ ^ no idea different windows mac deving on :/
Comments
Post a Comment