-
Notifications
You must be signed in to change notification settings - Fork 43
Home
Ved Prakash Singh edited this page Jan 27, 2016
·
34 revisions
We are using SparkCommon from Utils package to run the Examples of in this tutorial.
object SparkCommon {
lazy val conf = {
new SparkConf(false)
.setMaster("local[*]")
.setAppName("Spark Tutorial")
}
lazy val sparkContext = new SparkContext(conf)
lazy val sparkSQLContext = SQLContext.getOrCreate(sparkContext)
lazy val streamingContext = StreamingContext.getActive()
.getOrElse(new StreamingContext(sparkContext, Seconds(2)))
}