promquery

package module
v0.0.0-...-19b7113 Latest Latest
Warning

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

Go to latest
Published: Aug 4, 2021 License: Apache-2.0 Imports: 13 Imported by: 0

README

promquery

A tool manipulating and polling prometheus queries

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Poller

type Poller struct {
	Queries      []*PromQuery
	SuccessCount int
	// contains filtered or unexported fields
}

func NewPoller

func NewPoller(addrs []string, queries []string, successCount int) (*Poller, error)

func (*Poller) Init

func (p *Poller) Init(ctx context.Context)

func (*Poller) Wait

func (p *Poller) Wait(ctx context.Context, interval time.Duration, stddevThreshold uint, notifyMetrics func(string)) <-chan error

type PromQuery

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

func NewPromQuery

func NewPromQuery(query string) (*PromQuery, error)

func (*PromQuery) AddLabel

func (q *PromQuery) AddLabel(name, value string, equal bool) error

func (*PromQuery) AddRegexpLabel

func (q *PromQuery) AddRegexpLabel(name, value string, equal bool) error

func (*PromQuery) String

func (q *PromQuery) String() string

Directories

Path Synopsis
cmd

Jump to

Keyboard shortcuts

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