Using the elasticsearch-hadoop library I would like to read data from ElasticSearch straight into a Spark Dataset. However the API for that returns RDD[(String, Map[String, Any])] where the first element of the tuple is the document name and the second (the map) is the data itself.
I would like to turn this into a Dataset[T], where T is some case class, to make the returned data easier to work with. I would consider either using some other library (I couldn't find any) or a neat code solution.