关于ElasticSearch查询(多range使用)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
GET /apm-7.4.0-transaction*/_search
{
  "size": 100,
  "query": {
    "bool": {
      "must": [
        {
          "range": {
            "transaction.duration.us": {
              "gte": 30000000
            }
          }
        },
        {
          "range": {
            "@timestamp": {
              "gte": "2021-07-04 17:35:00",
              "lte": "2021-07-04 17:35:34",
              "format": "yyyy-MM-dd HH:mm:ss",
              "time_zone": "+08:00"
            }
          }
        }
      ]
    }
  },
  "_source": {
    "includes": [
      "@timestamp",
      "url.path",
      "url.full",
      "transaction.duration.us",
      "transaction.result"
    ]
  }
}
https://blog.51cto.com/u_709151/2985419
Licensed under CC BY-NC-SA 4.0
最后更新于 Jan 06, 2025 05:52 UTC
comments powered by Disqus
Built with Hugo
主题 StackJimmy 设计
Caret Up