metrics

package
v0.0.26 Latest Latest
Warning

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

Go to latest
Published: Mar 30, 2020 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package metrics provides metrics.

Index

Constants

This section is empty.

Variables

View Source
var (
	Int64   = stats.Int64
	Float64 = stats.Float64

	UnitDimensionless = stats.UnitDimensionless
	UnitBytes         = stats.UnitBytes
	UnitMilliseconds  = stats.UnitMilliseconds

	Count        = view.Count
	Distribution = view.Distribution
	LastValue    = view.LastValue
	Sum          = view.Sum

	NewKey = tag.NewKey

	ValdOrg = "vald.vdaas.org"
)

Functions

func MeasurementsCount

func MeasurementsCount(m Metric) int

func Record

func Record(ctx context.Context, ms ...Measurement)

func RecordWithTags

func RecordWithTags(ctx context.Context, mwts ...MeasurementWithTags) (errs error)

func RegisterView

func RegisterView(views ...*View) error

Types

type Float64Measure

type Float64Measure = stats.Float64Measure

type Int64Measure

type Int64Measure = stats.Int64Measure

type Key

type Key = tag.Key

type Measurement

type Measurement = stats.Measurement

type MeasurementWithTags

type MeasurementWithTags struct {
	Measurement Measurement
	Tags        map[Key]string
}

type Metric

type Metric interface {
	Measurement(ctx context.Context) ([]Measurement, error)
	MeasurementWithTags(ctx context.Context) ([]MeasurementWithTags, error)
	View() []*View
}

type View

type View = view.View

Directories

Path Synopsis
agent
ngt
Package ngt provides functions for ngt stats
Package ngt provides functions for ngt stats
Package grpc provides functions for grpc stats
Package grpc provides functions for grpc stats
Package mem provides memory metrics functions
Package mem provides memory metrics functions
runtime
cgo
Package cgo provides functions for runtime cgo stats
Package cgo provides functions for runtime cgo stats
goroutine
Package goroutine provides functions for goroutine runtime stats
Package goroutine provides functions for goroutine runtime stats
Package version provides version info metrics functions
Package version provides version info metrics functions

Jump to

Keyboard shortcuts

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