Skip to content

Commit

Permalink
add search.scroll_current metric (prometheus-community#220)
Browse files Browse the repository at this point in the history
  • Loading branch information
Sergey Yagodkin authored and zwopir committed Mar 4, 2019
1 parent 132384a commit 034fc72
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions collector/indices.go
Original file line number Diff line number Diff line change
Expand Up @@ -500,6 +500,18 @@ func NewIndices(logger log.Logger, client *http.Client, url *url.URL, shards boo
},
Labels: indexLabels,
},
{
Type: prometheus.GaugeValue,
Desc: prometheus.NewDesc(
prometheus.BuildFQName(namespace, "index_stats", "search_scroll_current"),
"Current search scroll count",
indexLabels.keys(), nil,
),
Value: func(indexStats IndexStatsIndexResponse) float64 {
return float64(indexStats.Total.Search.ScrollCurrent)
},
Labels: indexLabels,
},
{
Type: prometheus.CounterValue,
Desc: prometheus.NewDesc(
Expand Down

0 comments on commit 034fc72

Please sign in to comment.