Last active
August 3, 2021 22:32
-
-
Save RAbraham/585939e5390d46a7d6f8 to your computer and use it in GitHub Desktop.
Execute Apache Spark in a Scala IDE worksheet
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package org.apache.spark.graphx | |
import org.apache.spark.SparkContext | |
import org.apache.spark.SparkContext._ | |
import org.apache.spark.SparkConf | |
import org.apache.spark.rdd.RDD | |
import org.apache.spark._ | |
object repl { | |
val sc = new SparkContext("local", "test") //> sc : org.apache.spark.SparkContext = org.apache.spark.SparkContext@3724af13 | |
//| | |
val vertices = sc.parallelize(1L to 5L) //> vertices : org.apache.spark.rdd.RDD[Long] = ParallelCollectionRDD[0] at par | |
//| allelize at org.apache.spark.graphx.repl.scala:15 | |
println(vertices.count) //> 5 | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Yes, it solved it for me also. There are 4 options there (IntelliJ Idea Community edition 2016.3 on MacOs):
It worked for me when I checked only the third option and left the other three unchecked.