简体   繁体   English

如何在kibana中将查询输出表示为图形?

[英]How to represent query output in kibana to graph?

Kibana has dev tool. Kibana具有开发工具。 Where we can run the query and generate the output. 我们可以在其中运行查询并生成输出的地方。 How to visualise that query output in kibana dashboards ? 如何在kibana仪表板中可视化该查询输出?

see this 看到这个 question for further explanation. 有待进一步解释的问题。

Your question seems a bit broad. 您的问题似乎有点宽泛。 Let me skip some details and give you a general idea. 让我跳过一些细节,并给您一个总体思路。

In Kibana Dev Tools, you can run a query like below. 在Kibana Dev Tools中,您可以运行如下查询。

GET /bank/_search
{
  "size": 0,
  "aggs": {
    "group_by_state": {
      "terms": {
        "field": "state.keyword"
      }
    }
  }
}

And you will see results in your Console like this : 您将在控制台中看到如下结果:

在此处输入图片说明

In order to visualize it in your dashboard, first you need to create one visualization type in Visualize tab, and create your dashboard with it. 为了在仪表板中对其进行可视化,首先需要在“可视化”选项卡中创建一种可视化类型,然后使用它来创建仪表板。

在此处输入图片说明

I made a pie chart, but not with the query above. 我做了一个饼图,但没有上面的查询。 But I use the same logic. 但是我使用相同的逻辑。 You can see how I did it below. 您可以在下面查看我的操作方式。

在此处输入图片说明

Lastly, I created a dashboard and add the Visualization. 最后,我创建了一个仪表板并添加了可视化。

在此处输入图片说明

You can watch tutorial videos on how to create Visualization and Dashboard. 您可以观看有关如何创建可视化和仪表板的教程视频。 When you run into another question as you learn, you can ask here anytime on Stack Overflow. 当您在学习中遇到另一个问题时,可以随时在Stack Overflow上提问。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM