helpers

package
v0.0.0-...-d17e12a Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConfigHandler

func ConfigHandler(data []byte)

func GetCancelFunc

func GetCancelFunc() *context.CancelFunc

func GetLastPluginOutput

func GetLastPluginOutput(tag map[string]string) string

func GetMetricsProfile

func GetMetricsProfile() *transit.MonitorConnection

func GetMonitorConnection

func GetMonitorConnection() *transit.MetricsProfile

func Validate

func Validate(data template.Data) error

TODO: validate prometheus payload if needed

Types

type ExtConfig

type ExtConfig struct {
	MapHostgroup mapping.Mappings `json:"mapHostgroup"`
	MapHostname  mapping.Mappings `json:"mapHostname"`
	MapService   mapping.Mappings `json:"mapService"`
}

func GetExtConfig

func GetExtConfig() *ExtConfig

type ParseResult

type ParseResult struct {
	HostName      string
	HostGroupName string
	MetricBuilder connectors.MetricBuilder
}

func ParsePrometheusData

func ParsePrometheusData(data template.Data, cfg *ExtConfig) ([]ParseResult, error)

Jump to

Keyboard shortcuts

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