# What is the most efficient way to implement visualizations in dashboard

**URL:** <https://discuss.elastic.co/t/what-is-the-most-efficient-way-to-implement-visualizations-in-dashboard/52194>\
**Category:** Kibana\
**Created:** [June 8, 2016, 10:19am UTC](https://discuss.elastic.co/t/what-is-the-most-efficient-way-to-implement-visualizations-in-dashboard/52194 "2016-06-08T10:19:06Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mick\_Mahoney](https://avatars.discourse-cdn.com/v4/letter/m/cab0a1/32.png) [@Mick\_Mahoney](https://discuss.elastic.co/u/Mick_Mahoney)\
**Post date:** [June 8, 2016, 10:19am UTC](https://discuss.elastic.co/t/what-is-the-most-efficient-way-to-implement-visualizations-in-dashboard/52194/1 "2016-06-08T10:19:06Z")

</div>

I can have 1 visualization split on category showing 3 graphs for CPU for example (3 different categories of server)

Or I can have 3 separate visualizations (1 per category) which looks neater as the legend is on each graph and less cluttered.

If they all use the same underlying search, do I have to pull the data back 3 times from elasticsearch for the 3 separate visualizations, or since they are all in the same dashboard, does the search get executed only once ?

Many Thanks

Mick

---

<div class="post-metadata">

**Author:** ![tsullivan](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tsullivan/32/31077_2.png) [@tsullivan](https://discuss.elastic.co/u/tsullivan)\
**Post date:** [June 8, 2016, 8:18pm UTC](https://discuss.elastic.co/t/what-is-the-most-efficient-way-to-implement-visualizations-in-dashboard/52194/2 "2016-06-08T20:18:52Z")

</div>

Great question. The Kibana front-end registers all the queries that it needs to render a page, and sends them to Elasticsearch as an [`_msearch`](https://www.elastic.co/guide/en/elasticsearch/reference/current/search-multi-search.html).

The NodeJS server for Kibana proxies requests from the browser to the Elasticsearch connection, so you can actually see the msearch query being sent if you watch the network traffic from the browser.

So whether you have a single visualization or multiple, getting the data is a single query to Elasticsearch.

---

<div class="post-metadata">

**Author:** ![Mick\_Mahoney](https://avatars.discourse-cdn.com/v4/letter/m/cab0a1/32.png) [@Mick\_Mahoney](https://discuss.elastic.co/u/Mick_Mahoney)\
**Post date:** [June 9, 2016, 9:41am UTC](https://discuss.elastic.co/t/what-is-the-most-efficient-way-to-implement-visualizations-in-dashboard/52194/3 "2016-06-09T09:41:19Z")

</div>

That explains it very well, and thats what I was hoping - excellent 🙂

Many Thanks Tim,

Mick

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 1:51pm UTC](https://discuss.elastic.co/t/what-is-the-most-efficient-way-to-implement-visualizations-in-dashboard/52194/4 "2017-07-06T13:51:02Z")

</div>


