Kibana allows you to create reusable data representations called Visualizations. They are representations of aggregations and can be used to power up the dashboard with custom graphs.
Getting ready
You need an up-and-running Elasticsearch installation as we described in the Downloading and installing Elasticsearch recipe in Chapter 2, Downloading and Setup.
You also need a functional Kibana installation as described in Installing Kibana and X-Pack recipe. The X-Pack is not needed.
How to do it...
To use Kibana to create custom widgets, we will perform the following steps:
We access the Visualize section of Kibana as shown in the following screenshot:
Now we can choose the visualization that we want to create as shown in the following screenshot:
If we want to create a Tag cloud visualization, we select it and populate the required fields as shown in the following screenshot:
How it works...
Aggregations and searches can be grouped in the visualization widgets that can be used as building blocks for creating custom interfaces.
The built-in visualizations are as follows:
Area chart: This is useful to represent stacked timelines
Data table: This allows you to create a data table using aggregation results
Line chart: This is useful to represent time-based hits and compare them
Markdown widget: This is useful for displaying explanations or instructions for dashboards
Metric: This represents a numeric metric value
Pie chart: This is useful to represent low cardinality values
Tag cloud: This is useful to represent term values such as tags and labels
Tile map: This is useful to represent GeoPoint values
Time series: This allows you to use Timelion expression language to create time series charts
Vertical bar chart: This is the general purpose bar representation for histogram
After having selected a visualization, a custom form is presented on the left for allowing to populate all the required values. On the right, we have the widget representation updated in near-realtime with the result of the queries/aggregations.
After the configuration of the visualization is completed, it must be saved to be used as a widget in dashboards.