metrics

package
v0.0.0-...-43ccd23 Latest Latest
Warning

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

Go to latest
Published: Oct 7, 2021 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// Namespace defines the namespace for the defines metrics.
	Namespace = "ocis"

	// Subsystem defines the subsystem for the defines metrics.
	Subsystem = "ocis-eosprojects"
)

Functions

This section is empty.

Types

type Metrics

type Metrics struct {
	BuildInfo *prometheus.GaugeVec
	Counter   *prometheus.CounterVec
	Latency   *prometheus.SummaryVec
	Duration  *prometheus.HistogramVec
}

Metrics defines the available metrics of this service.

func New

func New(opts ...Option) *Metrics

New initializes the available metrics.

type Option

type Option func(o *Options)

Option defines a single option function.

func Logger

func Logger(val log.Logger) Option

Logger provides a function to set the logger option.

type Options

type Options struct {
	Logger log.Logger
}

Options defines the available options for this package.

Jump to

Keyboard shortcuts

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