mirror of
https://github.com/openfaas/faas.git
synced 2025-06-21 09:56:31 +00:00
Changed Metrics to be exposed via Exporter
This change exposes the gateway metrics with an exporter which implements the Collector interface of prometheus. This change Fixes #697 Signed-off-by: Ken Fukuyama <kenfdev@gmail.com>
This commit is contained in:
@ -54,8 +54,6 @@ func BuildMetricsOptions() MetricOptions {
|
||||
}
|
||||
|
||||
//RegisterMetrics registers with Prometheus for tracking
|
||||
func RegisterMetrics(metricsOptions MetricOptions) {
|
||||
prometheus.Register(metricsOptions.GatewayFunctionInvocation)
|
||||
prometheus.Register(metricsOptions.GatewayFunctionsHistogram)
|
||||
prometheus.Register(metricsOptions.ServiceReplicasCounter)
|
||||
func RegisterExporter(exporter *Exporter) {
|
||||
prometheus.MustRegister(exporter)
|
||||
}
|
||||
|
Reference in New Issue
Block a user