minimumhistory

package
v0.2.4 Latest Latest
Warning

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

Go to latest
Published: Aug 8, 2017 License: MIT Imports: 9 Imported by: 0

Documentation

Overview

Package minimumhistory implements target selection for multi-prometheus deployments by selecting an instance at random with a minimum amount of history available, and with sticky-session support

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Selector

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

Selector implements selction of a single prometheus endpoint out of a provided set of endpoints which has the highest value of total ingested samples

func (*Selector) ComparisonMetricName

func (s *Selector) ComparisonMetricName() string

ComparisonMetricName gets the name of the comparison metric/calculation used to make a selection

func (*Selector) Description

func (s *Selector) Description() string

Description provides a human-readable description for this strategy

func (*Selector) Name

func (s *Selector) Name() string

Name provides the (unique) name of this strategy

func (*Selector) NextIndex

func (s *Selector) NextIndex(targets []*url.URL) int

NextIndex returns the index of the target that should be used to field the next request

func (*Selector) Select

func (s *Selector) Select(endpoints []*locator.PrometheusEndpoint) (err error)

Select chooses elligible prometheus endpoints out of the provided set

Jump to

Keyboard shortcuts

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