proxyquerier

package
v0.0.87 Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2024 License: MIT Imports: 12 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ProxyQuerier

type ProxyQuerier struct {
	Ctx    context.Context
	Start  time.Time
	End    time.Time
	Client promclient.API

	Cfg *proxyconfig.PromxyConfig
}

ProxyQuerier Implements prometheus' Querier interface

func (*ProxyQuerier) Close

func (h *ProxyQuerier) Close() error

Close closes the querier. Behavior for subsequent calls to Querier methods is undefined.

func (*ProxyQuerier) LabelNames

func (h *ProxyQuerier) LabelNames(matchers ...*labels.Matcher) ([]string, storage.Warnings, error)

LabelNames returns all the unique label names present in the block in sorted order.

func (*ProxyQuerier) LabelValues

func (h *ProxyQuerier) LabelValues(name string, matchers ...*labels.Matcher) ([]string, storage.Warnings, error)

LabelValues returns all potential values for a label name.

func (*ProxyQuerier) Select

func (h *ProxyQuerier) Select(_ bool, hints *storage.SelectHints, matchers ...*labels.Matcher) storage.SeriesSet

Select returns a set of series that matches the given label matchers. TODO: switch based on sortSeries bool(first arg)

type Series

type Series struct {
	It *promclient.SeriesIterator
}

Series implements prometheus' Series interface

func (*Series) Iterator

func (s *Series) Iterator() chunkenc.Iterator

Iterator returns an iterator over the series

func (*Series) Labels

func (s *Series) Labels() labels.Labels

Labels for this seris

type SeriesSet

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

SeriesSet implements prometheus' SeriesSet interface

func NewSeriesSet

func NewSeriesSet(series []storage.Series, warnings storage.Warnings, err error) *SeriesSet

NewSeriesSet returns a SeriesSet for the given series

func (*SeriesSet) At

func (s *SeriesSet) At() storage.Series

At returns the current Series for this iterator

func (*SeriesSet) Err

func (s *SeriesSet) Err() error

Err returns any error found in this iterator

func (*SeriesSet) Next

func (s *SeriesSet) Next() bool

Next will attempt to move the iterator up

func (*SeriesSet) Warnings added in v0.0.63

func (s *SeriesSet) Warnings() storage.Warnings

Warnings returns a collection of warnings for the whole set. Note: Warnings could be returned even if iteration has not failed with an error.

Jump to

Keyboard shortcuts

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