Bump Prometheus client version

- updates the Prometheus go client version and switches to the
promhttp handler to avoid conflicts with the new system-level
metrics.

Tested with Docker Swarm locally - no conflicts and new metrics
were gathered.

Signed-off-by: Alex Ellis (VMware) <alexellis2@gmail.com>
This commit is contained in:
Alex Ellis (VMware)
2019-01-04 18:26:38 +00:00
committed by Alex Ellis
parent 64a3f4e495
commit e9cf708cb5
87 changed files with 10421 additions and 2580 deletions

View File

@ -7,6 +7,7 @@ import (
"net/http"
"github.com/prometheus/client_golang/prometheus"
"github.com/prometheus/client_golang/prometheus/promhttp"
)
// MetricOptions to be used by web handlers
@ -25,7 +26,7 @@ type ServiceMetricOptions struct {
// PrometheusHandler Bootstraps prometheus for metrics collection
func PrometheusHandler() http.Handler {
return prometheus.Handler()
return promhttp.Handler()
}
// BuildMetricsOptions builds metrics for tracking functions in the API gateway