prometheusmetrics

package
v0.0.0-...-97a8816 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 3, 2018 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Metrics

type Metrics struct {
	Registry *prometheus.Registry
	// contains filtered or unexported fields
}

Defines the actual Prometheus metrics we will be using. Satisfies interface MetricsEngine

func NewMetrics

func NewMetrics(cfg config.PrometheusMetrics) *Metrics

NewMetrics constructs the appropriate options for the Prometheus metrics. Needs to be fed the promethus config Its own function to keep the metric creation function cleaner.

func (*Metrics) RecordAdapterBidReceived

func (me *Metrics) RecordAdapterBidReceived(labels pbsmetrics.AdapterLabels, bidType openrtb_ext.BidType, hasAdm bool)

func (*Metrics) RecordAdapterPrice

func (me *Metrics) RecordAdapterPrice(labels pbsmetrics.AdapterLabels, cpm float64)

func (*Metrics) RecordAdapterRequest

func (me *Metrics) RecordAdapterRequest(labels pbsmetrics.AdapterLabels)

func (*Metrics) RecordAdapterTime

func (me *Metrics) RecordAdapterTime(labels pbsmetrics.AdapterLabels, length time.Duration)

func (*Metrics) RecordConnectionAccept

func (me *Metrics) RecordConnectionAccept(success bool)

func (*Metrics) RecordConnectionClose

func (me *Metrics) RecordConnectionClose(success bool)

func (*Metrics) RecordCookieSync

func (me *Metrics) RecordCookieSync(labels pbsmetrics.Labels)

func (*Metrics) RecordImps

func (me *Metrics) RecordImps(labels pbsmetrics.Labels, numImps int)

func (*Metrics) RecordRequest

func (me *Metrics) RecordRequest(labels pbsmetrics.Labels)

func (*Metrics) RecordRequestTime

func (me *Metrics) RecordRequestTime(labels pbsmetrics.Labels, length time.Duration)

func (*Metrics) RecordUserIDSet

func (me *Metrics) RecordUserIDSet(userLabels pbsmetrics.UserLabels)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL