In my use case, while submitting the applications as spark-submit --master yarn --deploy-mode client, the job runs fine. However, when the same is submitted spark-submit --master yarn --deploy-mode cluster, the job fails to initiate.
val conf = new SparkConf().setAppName("sample")
val sc = new SparkContext(conf)
val lines = sc.textFile("filepath")
I understand, I need to use SparkSession with Spark versions>2.0. However, could that be the only difference causing the issue. I am using an EMR to run the code, config
Master: 1 Core: 5 Nodes
Some questions, reading through some blogs/sites, looks like the cluster does get utilized irrespective the of the Spark-submit mode and the fact that the driver program kicks off differently in both submit modes. But however, i dont seem to understand the exact difference in approach. can some help be provided to understand what really slows down the execution, when "client" mode is used compared to "cluster".