promql

package
v0.188.0-fips1 Latest Latest
Warning

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

Go to latest
Published: Nov 22, 2022 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const ChangesKind = "changes"
View Source
const DefaultUpperBoundColumnLabel = "le"
View Source
const EmptyTableKind = "emptyTable"
View Source
const ExtrapolatedRateKind = "extrapolatedRate"
View Source
const HistogramQuantileKind = "promHistogramQuantile"

TODO: Added "prom" prefix to avoid duplicate registration error. Decide whether to remove universe version of this function.

View Source
const HoltWintersKind = "promHoltWinters"
View Source
const InstantRateKind = "instantRate"
View Source
const (
	// LabelReplaceKind is the Kind for the LabelReplace Flux function
	LabelReplaceKind = "labelReplace"
)
View Source
const LinearRegressionKind = "linearRegression"
View Source
const ResetsKind = "resets"
View Source
const (
	// TimestampKind is the Kind for the Timestamp Flux function
	TimestampKind = "timestamp"
)

Variables

This section is empty.

Functions

func NewChangesTransformation

func NewChangesTransformation(d execute.Dataset, cache execute.TableBuilderCache, spec *ChangesProcedureSpec) *changesTransformation

func NewExtrapolatedRateTransformation

func NewExtrapolatedRateTransformation(d execute.Dataset, cache execute.TableBuilderCache, spec *ExtrapolatedRateProcedureSpec) *extrapolatedRateTransformation

func NewHoltWintersTransformation

func NewHoltWintersTransformation(d execute.Dataset, cache execute.TableBuilderCache, spec *HoltWintersProcedureSpec) *holtWintersTransformation

func NewInstantRateTransformation

func NewInstantRateTransformation(d execute.Dataset, cache execute.TableBuilderCache, spec *InstantRateProcedureSpec) *instantRateTransformation

func NewLabelReplaceTransformation

func NewLabelReplaceTransformation(d execute.Dataset, cache execute.TableBuilderCache, spec *LabelReplaceProcedureSpec) *labelReplaceTransformation

func NewLinearRegressionTransformation

func NewLinearRegressionTransformation(d execute.Dataset, cache execute.TableBuilderCache, spec *LinearRegressionProcedureSpec) *linearRegressionTransformation

func NewResetsTransformation

func NewResetsTransformation(d execute.Dataset, cache execute.TableBuilderCache, spec *ResetsProcedureSpec) *resetsTransformation

func NewTimestampTransformation

func NewTimestampTransformation(d execute.Dataset, cache execute.TableBuilderCache, spec *TimestampProcedureSpec) *timestampTransformation

Types

type ChangesOpSpec

type ChangesOpSpec struct{}

func (*ChangesOpSpec) Kind

func (s *ChangesOpSpec) Kind() flux.OperationKind

type ChangesProcedureSpec

type ChangesProcedureSpec struct {
	plan.DefaultCost
}

func (*ChangesProcedureSpec) Copy

func (*ChangesProcedureSpec) Kind

func (*ChangesProcedureSpec) TriggerSpec

func (s *ChangesProcedureSpec) TriggerSpec() plan.TriggerSpec

TriggerSpec implements plan.TriggerAwareProcedureSpec

type EmptyTableOpSpec

type EmptyTableOpSpec struct{}

func (*EmptyTableOpSpec) Kind

type EmptyTableProcedureSpec

type EmptyTableProcedureSpec struct {
	plan.DefaultCost
}

func (*EmptyTableProcedureSpec) Copy

func (*EmptyTableProcedureSpec) Kind

type EmptyTableSource

type EmptyTableSource struct {
	execute.ExecutionNode
	// contains filtered or unexported fields
}

func (*EmptyTableSource) AddTransformation

func (s *EmptyTableSource) AddTransformation(t execute.Transformation)

func (*EmptyTableSource) Run

func (s *EmptyTableSource) Run(ctx context.Context)

type ExtrapolatedRateOpSpec

type ExtrapolatedRateOpSpec struct {
	IsCounter bool `json:"isCounter"`
	IsRate    bool `json:"isRate"`
}

func (*ExtrapolatedRateOpSpec) Kind

type ExtrapolatedRateProcedureSpec

type ExtrapolatedRateProcedureSpec struct {
	plan.DefaultCost
	IsCounter bool
	IsRate    bool
}

func (*ExtrapolatedRateProcedureSpec) Copy

func (*ExtrapolatedRateProcedureSpec) Kind

func (*ExtrapolatedRateProcedureSpec) TriggerSpec

TriggerSpec implements plan.TriggerAwareProcedureSpec

type HistogramQuantileOpSpec

type HistogramQuantileOpSpec struct {
	Quantile         float64 `json:"quantile"`
	CountColumn      string  `json:"countColumn"`
	UpperBoundColumn string  `json:"upperBoundColumn"`
	ValueColumn      string  `json:"valueColumn"`
}

func (*HistogramQuantileOpSpec) Kind

type HistogramQuantileProcedureSpec

type HistogramQuantileProcedureSpec struct {
	plan.DefaultCost
	Quantile         float64 `json:"quantile"`
	CountColumn      string  `json:"countColumn"`
	UpperBoundColumn string  `json:"upperBoundColumn"`
	ValueColumn      string  `json:"valueColumn"`
}

func (*HistogramQuantileProcedureSpec) Copy

func (*HistogramQuantileProcedureSpec) Kind

type HoltWintersOpSpec

type HoltWintersOpSpec struct {
	SmoothingFactor float64 `json:"smoothingFactor"`
	TrendFactor     float64 `json:"trendFactor"`
}

func (*HoltWintersOpSpec) Kind

type HoltWintersProcedureSpec

type HoltWintersProcedureSpec struct {
	plan.DefaultCost
	SmoothingFactor float64
	TrendFactor     float64
}

func (*HoltWintersProcedureSpec) Copy

func (*HoltWintersProcedureSpec) Kind

func (*HoltWintersProcedureSpec) TriggerSpec

func (s *HoltWintersProcedureSpec) TriggerSpec() plan.TriggerSpec

TriggerSpec implements plan.TriggerAwareProcedureSpec

type InstantRateOpSpec

type InstantRateOpSpec struct {
	IsRate bool `json:"isRate"`
}

func (*InstantRateOpSpec) Kind

type InstantRateProcedureSpec

type InstantRateProcedureSpec struct {
	plan.DefaultCost
	IsRate bool
}

func (*InstantRateProcedureSpec) Copy

func (*InstantRateProcedureSpec) Kind

func (*InstantRateProcedureSpec) TriggerSpec

func (s *InstantRateProcedureSpec) TriggerSpec() plan.TriggerSpec

TriggerSpec implements plan.TriggerAwareProcedureSpec

type LabelReplaceOpSpec

type LabelReplaceOpSpec struct {
	Source      string `json:"source"`
	Destination string `json:"destination"`
	Regex       string `json:"regex"`
	Replacement string `json:"replacement"`
}

func (*LabelReplaceOpSpec) Kind

type LabelReplaceProcedureSpec

type LabelReplaceProcedureSpec struct {
	plan.DefaultCost
	Source      string
	Destination string
	Regex       string
	Replacement string
}

func (*LabelReplaceProcedureSpec) Copy

func (*LabelReplaceProcedureSpec) Kind

type LinearRegressionOpSpec

type LinearRegressionOpSpec struct {
	Predict bool `json:"predict"`
	// Stored as seconds in float64 to avoid back-and-forth duration conversions from PromQL.
	FromNow float64 `json:"fromNow"`
}

func (*LinearRegressionOpSpec) Kind

type LinearRegressionProcedureSpec

type LinearRegressionProcedureSpec struct {
	plan.DefaultCost
	Predict bool
	FromNow float64
}

func (*LinearRegressionProcedureSpec) Copy

func (*LinearRegressionProcedureSpec) Kind

func (*LinearRegressionProcedureSpec) TriggerSpec

TriggerSpec implements plan.TriggerAwareProcedureSpec

type ResetsOpSpec

type ResetsOpSpec struct{}

func (*ResetsOpSpec) Kind

func (s *ResetsOpSpec) Kind() flux.OperationKind

type ResetsProcedureSpec

type ResetsProcedureSpec struct {
	plan.DefaultCost
}

func (*ResetsProcedureSpec) Copy

func (*ResetsProcedureSpec) Kind

func (*ResetsProcedureSpec) TriggerSpec

func (s *ResetsProcedureSpec) TriggerSpec() plan.TriggerSpec

TriggerSpec implements plan.TriggerAwareProcedureSpec

type TimestampOpSpec

type TimestampOpSpec struct{}

func (*TimestampOpSpec) Kind

type TimestampProcedureSpec

type TimestampProcedureSpec struct {
	plan.DefaultCost
}

func (*TimestampProcedureSpec) Copy

func (*TimestampProcedureSpec) Kind

Jump to

Keyboard shortcuts

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