I can create a RDD from ElasticSearch using query string as follow
val sc: SparkContext = getSparkContext()
val rdd = sc.esRDD("myindex/mytype", "?q=myterm")
How can I use ElasticSearch DSL syntax to specify the query?
I can create a RDD from ElasticSearch using query string as follow
val sc: SparkContext = getSparkContext()
val rdd = sc.esRDD("myindex/mytype", "?q=myterm")
How can I use ElasticSearch DSL syntax to specify the query?
Check out the example in following link:
https://www.elastic.co/guide/en/elasticsearch/hadoop/current/configuration.html#_querying
© 2020. All Rights Reserved - Elasticsearch
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant logo are trademarks of the Apache Software Foundation in the United States and/or other countries.