mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Update time_series_query.go
fix alert no data when elasticsearch group by terms size is set to no limit
This commit is contained in:
parent
974eddee8f
commit
3b9ab6e204
@ -171,6 +171,10 @@ func addTermsAgg(aggBuilder es.AggBuilder, bucketAgg *BucketAgg, metrics []*Metr
|
|||||||
} else {
|
} else {
|
||||||
a.Size = 500
|
a.Size = 500
|
||||||
}
|
}
|
||||||
|
if a.Size == 0 {
|
||||||
|
a.Size = 500
|
||||||
|
}
|
||||||
|
|
||||||
if minDocCount, err := bucketAgg.Settings.Get("min_doc_count").Int(); err == nil {
|
if minDocCount, err := bucketAgg.Settings.Get("min_doc_count").Int(); err == nil {
|
||||||
a.MinDocCount = &minDocCount
|
a.MinDocCount = &minDocCount
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user