Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( BuildInfo = prometheus.NewGaugeVec(prometheus.GaugeOpts{ Name: "build_info", Help: "Build information", }, []string{"version", "commit", "date"}) Up = prometheus.NewGaugeVec(prometheus.GaugeOpts{ Name: "up", Help: "service up", }, []string{"service"}) )
Functions ¶
func ErrorHandler ¶
func InitMetrics ¶
func InitMetrics(name, version, gitCommit, BuildTs string)
Types ¶
type MetricsServer ¶
type MetricsServer = Server
type Server ¶
func NewMetricsServer ¶
func NewMetricsServer() *Server
func NewServer ¶
func NewServer(opts ...ServerOption) *Server
type ServerOption ¶
type ServerOption func(*Server)
ServerOption is an HTTP server option.
func Gatherer ¶
func Gatherer(gatherer prometheus.Gatherer) ServerOption
func Path ¶
func Path(path string) ServerOption
Click to show internal directories.
Click to hide internal directories.