Exception in thread "main" java.lang.NoSuchMethodError: org.elasticsearch.spark.sql.EsSparkSQL$.saveToEs
The above error occurring when inserting the document from Spark application to the Elasticsearch cluster.
val conf = new SparkConf()
.setAppName("test")
.setMaster("local[*]")
val sc = new SparkContext(conf) val df =.. EsSparkSQL.saveToEs(df,> index, config)