v2

package
v0.0.0-...-a0c03a0 Latest Latest
Warning

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

Go to latest
Published: Jul 30, 2021 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Counter

type Counter struct {
	Namespace string
	Name      string
	Help      string
	// contains filtered or unexported fields
}

Counter represents the options required for prometheus.Counter and reference to the created prometheus.Counter.

func (*Counter) Create

func (c *Counter) Create() error

Create a new counter.

func (*Counter) Destroy

func (c *Counter) Destroy() error

Remove counter..

func (*Counter) Incr

func (c *Counter) Incr() error

Increment the counter by 1.

type CounterVec

type CounterVec struct {
	Namespace string
	Name      string
	Help      string
	// contains filtered or unexported fields
}

CounterVec represents the options required for prometheus.CounterVec and reference to the created prometheus.CounterVec.

func (*CounterVec) Create

func (c *CounterVec) Create(labels []string) error

Create a new counter vec.

func (*CounterVec) Incr

func (c *CounterVec) Incr(labels map[string]string) error

Increment counter for given label and value.

type Handler

type Handler struct {
	// contains filtered or unexported fields
}

func NewHandler

func NewHandler() *Handler

func (*Handler) ServeHTTP

func (h *Handler) ServeHTTP(rw of.ResponseWriter, r of.Request)

type HistogramVec

type HistogramVec struct {
	Namespace string
	Name      string
	Help      string
	// contains filtered or unexported fields
}

HistogramVec represents the options required for prometheus.HistogramVec and reference to the created prometheus.HistogramVec.

func (*HistogramVec) Create

func (c *HistogramVec) Create(labels []string) error

Create a new histogram vec.

func (*HistogramVec) Observed

func (c *HistogramVec) Observed(values []string, timeTaken float64) error

Increment histogram for given label and value.

Jump to

Keyboard shortcuts

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