Documentation ¶
Overview ¶
Package collector includes all individual collectors to gather and export system metrics.
Index ¶
- Constants
- Variables
- type Collector
- func NewBuddyinfoCollector() (Collector, error)
- func NewCPUCollector() (Collector, error)
- func NewFilesystemCollector() (Collector, error)
- func NewGmondCollector() (Collector, error)
- func NewLoadavgCollector() (Collector, error)
- func NewMegaCliCollector() (Collector, error)
- func NewMeminfoCollector() (Collector, error)
- func NewNetDevCollector() (Collector, error)
- func NewNtpCollector() (Collector, error)
- func NewRunitCollector() (Collector, error)
- func NewSupervisordCollector() (Collector, error)
- func NewTextFileCollector() (Collector, error)
- func NewTimeCollector() (Collector, error)
Constants ¶
const ClocksPerSec = float64(128)
default value. from time.h
const (
MNT_RDONLY = 0x1
)
const Namespace = "node"
Namespace defines the common namespace to be used by all metrics.
Variables ¶
var Factories = make(map[string]func() (Collector, error))
Factories contains the list of all available collectors.
Functions ¶
This section is empty.
Types ¶
type Collector ¶
type Collector interface { // Get new metrics and expose them via prometheus registry. Update(ch chan<- prometheus.Metric) error }
Collector is the interface a collector has to implement.
func NewBuddyinfoCollector ¶ added in v0.14.0
NewBuddyinfoCollector returns a new Collector exposing buddyinfo stats.
func NewCPUCollector ¶ added in v0.14.0
Takes a prometheus registry and returns a new Collector exposing CPU stats.
func NewFilesystemCollector ¶
NewFilesystemCollector returns a new Collector exposing filesystems stats.
func NewGmondCollector ¶
NewGmondCollector returns a new Collector scraping ganglia.
func NewLoadavgCollector ¶
NewLoadavgCollector returns a new Collector exposing load average stats.
func NewMegaCliCollector ¶
NewMegaCliCollector returns a new Collector exposing RAID status through megacli.
func NewMeminfoCollector ¶
NewMeminfoCollector returns a new Collector exposing memory stats.
func NewNetDevCollector ¶ added in v0.14.0
NewNetDevCollector returns a new Collector exposing network device stats.
func NewNtpCollector ¶
NewNtpCollector returns a new Collector exposing the offset between ntp and the current system time.
func NewRunitCollector ¶
NewRunitCollector returns a new Collector exposing runit statistics.
func NewSupervisordCollector ¶
NewSupervisordCollector returns a new Collector exposing supervisord statistics.
func NewTextFileCollector ¶
NewTextFileCollector returns a new Collector exposing metrics read from files in the given textfile directory.
func NewTimeCollector ¶
NewTimeCollector returns a new Collector exposing the current system time in seconds since epoch.