File: threads.libsonnet

package info (click to toggle)
prometheus-elasticsearch-exporter 1.9.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,664 kB
  • sloc: sh: 63; makefile: 37
file content (24 lines) | stat: -rw-r--r-- 612 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
local g = import '../g.libsonnet';
local prometheusQuery = g.query.prometheus;

local variables = import '../variables.libsonnet';

{
  threadPoolActive:
    prometheusQuery.new(
      '$' + variables.datasource.name,
      |||
        elasticsearch_thread_pool_active_count{cluster=~"$cluster"}
      |||
    )
    + prometheusQuery.withLegendFormat('{{type}}'),

  threadPoolRejections:
    prometheusQuery.new(
      '$' + variables.datasource.name,
      |||
        elasticsearch_thread_pool_rejected_count{cluster=~"$cluster"}
      |||
    )
    + prometheusQuery.withLegendFormat('{{name}} {{type}}'),
}