helper

package
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: Apr 6, 2017 License: AGPL-3.0 Imports: 8 Imported by: 4

Documentation

Index

Constants

View Source
const (
	TYPE_UNIX = "unix"
	TYPE_TCP  = "tcp"
)

Variables

View Source
var UnsupportedProtocolError = errors.New("This protocol is not supported")

Functions

func ParseCommaThresholds

func ParseCommaThresholds(warning, critical string) (*map[string][]*check_x.Threshold, error)

func SliceIndex

func SliceIndex(limit int, predicate func(i int) bool) int

SliceIndex from: http://stackoverflow.com/a/18203895

Types

type Livestatus

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

Livestatus fetches data from livestatus.

func NewLivestatus

func NewLivestatus(address string) (*Livestatus, error)

func (Livestatus) Query

func (l Livestatus) Query(query string) (*[][]string, error)

Queries livestatus and returns an list of list outer list are lines inner elements within the line.

Jump to

Keyboard shortcuts

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