elasticsearch/kibana — pull request #226 by justfalter (2013-07-17 22:37:37+00:00)
Title: Retrieve field names from _mapping API

I've got many different datasources feeding through Logstash into Elasticsearch, and many of them have very complex data types. This code provides a service that will query the Elasticsearch _mapping API for currently relevant indices, and distill a list of all possible field names.

- _mapping results are cached so that it only attempts to retrieve mappings that it doesn't have, already.
- I've provided a simple demo panel that shows all of the available fields (with the exception of multi_field descendants)
- The demo shows that mappings are only retrieved for indices that are currently relevant (via dashboard.indices).

I'm a bit of an angularJS n00b, so I'm not 100% certain how the core-devs would want to integrate functionality like this. However, I would imagine that it would remove the dependence upon the tables panel for field names, and allow for providing a definitive source of field names from a centralized place.