Documentation
¶
Index ¶
- type PrometheusMetrics
- func (hm *PrometheusMetrics) RecordLatency(latency time.Duration)
- func (hm *PrometheusMetrics) ServiceDown()
- func (hm *PrometheusMetrics) ServiceUp()
- func (hm *PrometheusMetrics) StartLatencyGauge(name string, group string, monitorName types.MonitorType)
- func (hm *PrometheusMetrics) StartServiceStatusGauge(name string, group string, monitorName types.MonitorType)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PrometheusMetrics ¶
type PrometheusMetrics struct {
ServiceStatusGauge prometheus.Gauge
LatencyGauge prometheus.Gauge
LatencyHistogram prometheus.Histogram
}
PrometheusMetrics the metrics for the monitor
func (*PrometheusMetrics) RecordLatency ¶
func (hm *PrometheusMetrics) RecordLatency(latency time.Duration)
RecordLatency records the latency
func (*PrometheusMetrics) ServiceDown ¶
func (hm *PrometheusMetrics) ServiceDown()
ServiceDown handles the service down
func (*PrometheusMetrics) ServiceUp ¶
func (hm *PrometheusMetrics) ServiceUp()
ServiceUp handles the service up
func (*PrometheusMetrics) StartLatencyGauge ¶
func (hm *PrometheusMetrics) StartLatencyGauge(name string, group string, monitorName types.MonitorType)
StartLatencyGauge initializes the latency gauge
func (*PrometheusMetrics) StartServiceStatusGauge ¶
func (hm *PrometheusMetrics) StartServiceStatusGauge(name string, group string, monitorName types.MonitorType)
StartServiceStatusGauge initializes the service status gauge
Click to show internal directories.
Click to hide internal directories.