Based on the elasticsearch document, the nested object seems the only option we can use. However, looks like Kibana does not support that well, throwing a warning says "array of object is not well supported". We can't use query like students.age: 9 to get certain records.
There are plans to support it, but it hasn't been scheduled yet.
If you're just interested in building visualizations, you may be able to use the Vega-visualization (https://www.elastic.co/blog/custom-vega-visualizations-in-kibana). It allows you to put in a raw ES-query, rather than using the Kibana-UX for formulate your query. So you could query an index directly, working around the current Kibana limitation.
I actually haven't tested this, so YMMV, but it may be worth looking into.
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.