Skip to content

Commit

Permalink
make metrics name consistent
Browse files Browse the repository at this point in the history
  • Loading branch information
Maciej Winnicki committed Nov 9, 2017
1 parent 9221bed commit 935302b
Showing 1 changed file with 16 additions and 16 deletions.
32 changes: 16 additions & 16 deletions router/metrics.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,58 +20,58 @@ func init() {
var routerEventsAsyncReceived = prometheus.NewCounter(
prometheus.CounterOpts{
Namespace: "gateway",
Subsystem: "router",
Name: "events_async_received_total",
Subsystem: "events",
Name: "async_received_total",
Help: "Total of asynchronously handled events received (including system events).",
})

var routerEventsAsyncDropped = prometheus.NewCounter(
prometheus.CounterOpts{
Namespace: "gateway",
Subsystem: "router",
Name: "events_async_dropped_total",
Subsystem: "events",
Name: "async_dropped_total",
Help: "Total of asynchronously handled events dropped due to insufficient processing power.",
})

var routerEventsAsyncProceeded = prometheus.NewCounter(
prometheus.CounterOpts{
Namespace: "gateway",
Subsystem: "router",
Name: "events_async_proceeded_total",
Subsystem: "events",
Name: "async_proceeded_total",
Help: "Total of asynchronously proceeded events.",
})

var routerEventsSyncReceived = prometheus.NewCounter(
prometheus.CounterOpts{
Namespace: "gateway",
Subsystem: "router",
Name: "events_sync_received_total",
Subsystem: "events",
Name: "sync_received_total",
Help: "Total of synchronously handled (HTTP and invoke) events received.",
})

var routerEventsSyncProceeded = prometheus.NewCounter(
prometheus.CounterOpts{
Namespace: "gateway",
Subsystem: "router",
Name: "events_sync_proceeded_total",
Subsystem: "events",
Name: "sync_proceeded_total",
Help: "Total of synchronously proceeded events. This counter excludes events for which there was no function " +
"registered or error occured during processing phase.",
})

var routerBacklog = prometheus.NewGauge(
prometheus.GaugeOpts{
Namespace: "gateway",
Subsystem: "router",
Name: "backlog_events",
Help: "Gauge of asynchronous events count waiting to be processed by the router.",
Subsystem: "events",
Name: "backlog",
Help: "Gauge of asynchronous events count waiting to be processed.",
})

var routerProcessingDuration = prometheus.NewHistogram(
prometheus.HistogramOpts{
Namespace: "gateway",
Subsystem: "router",
Name: "event_processing_seconds",
Help: "Bucketed histogram of processing duration of an event in the router. " +
Subsystem: "events",
Name: "async_processing_seconds",
Help: "Bucketed histogram of processing duration of an event. " +
"From receiving the asynchronous event to calling a function.",
Buckets: prometheus.ExponentialBuckets(0.00001, 2, 20),
})
Expand Down

0 comments on commit 935302b

Please sign in to comment.