metrics

package
v0.0.0-...-4c11209 Latest Latest
Warning

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

Go to latest
Published: Mar 24, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DBMonitor

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

DBMonitor monitor a db pool.

func NewDBMonitor

func NewDBMonitor(db *sql.DB) *DBMonitor

NewDBMonitor create a new db pool monitor.

func (*DBMonitor) Start

func (dbm *DBMonitor) Start()

Start start the collector.

type LogWriter

type LogWriter struct{}

LogWriter write metrics to the logger.

func New

func New(cfg *conf.Config) *LogWriter

New create a new log writer for metrics.

func (*LogWriter) Start

func (mr *LogWriter) Start()

Start start the writer.

func (*LogWriter) Write

func (mr *LogWriter) Write(data []byte) (int, error)

Jump to

Keyboard shortcuts

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