touchkit

package
v0.1.5 Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2024 License: Apache-2.0 Imports: 5 Imported by: 1

Documentation

Overview

Package touchkit adds integration with go-kit's metrics API with prometheus as the backend. This package's primary use case is to allow code written against go-kit's metrics package to participate in dependency injection via touchstone.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Counter

func Counter(o prometheus.CounterOpts, labelNames ...string) fx.Option

Counter uses an injected touchstone Factory to create a go-kit metrics.Counter backed by a prometheus CounterVec. The *touchstone.Factory from the enclosing fx.App is used to create and register the prometheus metric. The name of the returned component will be the same as the metric name.

func Gauge

func Gauge(o prometheus.GaugeOpts, labelNames ...string) fx.Option

Gauge uses an injected touchstone Factory to create a go-kit metrics.Gauge backed by a prometheus GaugeVec. The *touchstone.Factory from the enclosing fx.App is used to create and register the prometheus metric. The name of the returned component will be the same as the metric name.

func Histogram

func Histogram(o prometheus.HistogramOpts, labelNames ...string) fx.Option

Histogram uses an injected touchstone Factory to create a go-kit metrics.Histogram backed by a prometheus HistogramVec. The *touchstone.Factory from the enclosing fx.App is used to create and register the prometheus metric. The name of the returned component will be the same as the metric name.

func Summary

func Summary(o prometheus.SummaryOpts, labelNames ...string) fx.Option

Summary uses an injected touchstone Factory to create a go-kit metrics.Histogram backed by a prometheus SummaryVec. The *touchstone.Factory from the enclosing fx.App is used to create and register the prometheus metric. The name of the returned component will be the same as the metric name.

Types

This section is empty.

Jump to

Keyboard shortcuts

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