Documentation
¶
Overview ¶
Package random implements target selection for multi-prometheus deployments by selecting an instance at random with sticky-session support
Index ¶
- type Selector
- func (s *Selector) ComparisonMetricName() string
- func (s *Selector) Description() string
- func (s *Selector) Name() string
- func (s *Selector) NextIndex(targets []*url.URL) int
- func (s *Selector) RequiresStickySessions() bool
- func (s *Selector) Select(endpoints []*locator.PrometheusEndpoint) (err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Selector ¶
type Selector struct {
}
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 ¶
ComparisonMetricName gets the name of the comparison metric/calculation used to make a selection
func (*Selector) Description ¶
Description provides a human-readable description for this strategy
func (*Selector) NextIndex ¶
NextIndex returns the index of the target that should be used to field the next request
func (*Selector) RequiresStickySessions ¶
RequiresStickySessions answers whether this strategy needs sticky sessions
Click to show internal directories.
Click to hide internal directories.