collect

package
v0.0.0-...-24d954f Latest Latest
Warning

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

Go to latest
Published: May 18, 2020 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// SensuPluginPaths is sensu plugin search paths. combined with `,`
	SensuPluginPaths = halib.DefaultSensuPluginPaths
)

Functions

func GetCollectedMetrics

func GetCollectedMetrics() []halib.MetricsData

GetCollectedMetrics returns collected metrics. with no limit

func GetCollectedMetricsWithLimit

func GetCollectedMetricsWithLimit(limit int) []halib.MetricsData

GetCollectedMetricsWithLimit returns collected metrics. with max `limit`

func GetMetricConfig

func GetMetricConfig(configFile string) (halib.MetricConfig, error)

GetMetricConfig returns required metrics from config file

func GetMetricDataBufferStatus

func GetMetricDataBufferStatus(extended bool) map[string]int64

GetMetricDataBufferStatus returns metric collection status

func Metrics

func Metrics(configPath string) error

Metrics is main function of metric collection

func ParseMetricData

func ParseMetricData(rawMetricdata string) (map[string]float64, int64, error)

ParseMetricData parse sensu-stype metrics output

func SaveMetricConfig

func SaveMetricConfig(config halib.MetricConfig, configFile string) error

SaveMetricConfig save metric config to config file

func SaveMetrics

func SaveMetrics(now time.Time, metricsData []halib.MetricsData) error

SaveMetrics save metrics to dbms

Types

This section is empty.

Jump to

Keyboard shortcuts

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