mirror of
https://github.com/openfaas/faas.git
synced 2025-06-09 00:36:46 +00:00
Make gateway compatible with Prometheus 1.0 and 2.0
Signed-off-by: Alex Ellis <alexellis2@gmail.com>
This commit is contained in:
parent
fe02ef5151
commit
262b0afda7
@ -30,7 +30,7 @@ func NewPrometheusQuery(host string, port int, client *http.Client) PrometheusQu
|
||||
// Fetch queries aggregated stats
|
||||
func (q PrometheusQuery) Fetch(query string) (*VectorQueryResponse, error) {
|
||||
|
||||
req, reqErr := http.NewRequest(http.MethodGet, fmt.Sprintf("http://%s:%d/api/v1/query/?query=%s", q.Host, q.Port, query), nil)
|
||||
req, reqErr := http.NewRequest(http.MethodGet, fmt.Sprintf("http://%s:%d/api/v1/query?query=%s", q.Host, q.Port, query), nil)
|
||||
if reqErr != nil {
|
||||
return nil, reqErr
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user