IntelliJ IDEA 首次运行SparkPi遇到问题

问题1:

在运行spark的测试程序SparkPi时,点击运行,出现了如下错误:

Exception in thread "main" org.apache.spark.SparkException: A master URL must be set in your configuration

点击edit configuration,在左侧点击该项目。在右侧VM options中输入“-Dspark.master=local”,指示本程序本地单线程运行,再次运行即可。

配置如图

IntelliJ IDEA 首次运行SparkPi遇到问题_第1张图片


你可能感兴趣的:(IntelliJ IDEA 首次运行SparkPi遇到问题)