metrics

package
v0.0.7 Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2024 License: BSD-2-Clause Imports: 9 Imported by: 0

Documentation

Overview

Package metrics implements a standalone HTTP server for serving pprof profiles and Prometheus metrics.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddressFamily

func AddressFamily(ip netip.Addr) string

AddressFamily returns the label value for reporting the address family of an IP address.

func Enabled

func Enabled() bool

Enabled indicates that configured at least one metrics server

Types

type Server

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

Server represents a standalone HTTP server for serving a Prometheus metrics endpoint.

func NewServer

func NewServer(addr string) *Server

NewServer creates a new instance of a Prometheus server that asynchronously serves requests.

func (*Server) Close added in v0.0.4

func (s *Server) Close() error

Close shuts down the server.

Jump to

Keyboard shortcuts

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