mirror of
https://github.com/VictoriaMetrics/VictoriaMetrics.git
synced 2024-12-15 00:13:30 +01:00
vmctl: check error in response from influxdb (#5446)
(cherry picked from commit 27668c9d01
)
This commit is contained in:
parent
73f843a70e
commit
61f940591f
@ -360,6 +360,9 @@ func (c *Client) do(q influx.Query) ([]queryValues, error) {
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("query %q err: %s", q.Command, err)
|
||||
}
|
||||
if res.Error() != nil {
|
||||
return nil, fmt.Errorf("query %q err: %s", q.Command, res.Error())
|
||||
}
|
||||
if len(res.Results) < 1 {
|
||||
return nil, fmt.Errorf("exploration query %q returned 0 results", q.Command)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user