Cannot call methods on a stopped SparkContext while creating SparkSession

Viewed 83

I tried to run ScalaTest at my local. And I got an error pointing to SparkSession creation. I have no clue why this error message pops up. Please refer to the image for more details. enter image description here

The solution I have tried is to look up if there's any spark.stop() code in my codeset, but found none. I wonder if anyone has any ideas why it stops at the pointing line (line 53 in the image.)

val spark: SparkSession = SparkSession.builder().master("local[*]").appName("Data Validation").config("spark.sql.autoBroadcastJoinThreshold", -1).getOrCreate()

Thanks!

0 Answers
Related