Versions in this module Expand all Collapse all v1 v1.8.2 Nov 4, 2017 Changes in this version + const LowestPrec + var DefaultEngineOptions = &EngineOptions + var StalenessDelta = 5 * time.Minute + func Inspect(node Node, f func(Node) bool) + func ParseMetric(input string) (m model.Metric, err error) + func ParseMetricSelector(input string) (m metric.LabelMatchers, err error) + func Tree(node Node) string + func Walk(v Visitor, node Node) + type AggregateExpr struct + Expr Expr + Grouping model.LabelNames + KeepCommonLabels bool + Op itemType + Param Expr + Without bool + func (e *AggregateExpr) Type() model.ValueType + func (node *AggregateExpr) String() string + type AlertStmt struct + Annotations model.LabelSet + Duration time.Duration + Expr Expr + Labels model.LabelSet + Name string + func (node *AlertStmt) String() string + type BinaryExpr struct + LHS Expr + Op itemType + RHS Expr + ReturnBool bool + VectorMatching *VectorMatching + func (e *BinaryExpr) Type() model.ValueType + func (node *BinaryExpr) String() string + type Call struct + Args Expressions + Func *Function + func (e *Call) Type() model.ValueType + func (node *Call) String() string + type Engine struct + func NewEngine(queryable Queryable, o *EngineOptions) *Engine + func (ng *Engine) NewInstantQuery(qs string, ts model.Time) (Query, error) + func (ng *Engine) NewRangeQuery(qs string, start, end model.Time, interval time.Duration) (Query, error) + type EngineOptions struct + MaxConcurrentQueries int + Timeout time.Duration + type ErrQueryCanceled string + func (e ErrQueryCanceled) Error() string + type ErrQueryTimeout string + func (e ErrQueryTimeout) Error() string + type ErrStorage error + type EvalStmt struct + End model.Time + Expr Expr + Interval time.Duration + Start model.Time + func (node *EvalStmt) String() string + type Expr interface + Type func() model.ValueType + func ParseExpr(input string) (Expr, error) + type Expressions []Expr + func (es Expressions) String() (s string) + type Function struct + ArgTypes []model.ValueType + Call func(ev *evaluator, args Expressions) model.Value + Name string + ReturnType model.ValueType + Variadic int + type MatrixSelector struct + LabelMatchers metric.LabelMatchers + Name string + Offset time.Duration + Range time.Duration + func (e *MatrixSelector) Type() model.ValueType + func (node *MatrixSelector) String() string + type Node interface + String func() string + type NumberLiteral struct + Val model.SampleValue + func (e *NumberLiteral) Type() model.ValueType + func (node *NumberLiteral) String() string + type ParenExpr struct + Expr Expr + func (e *ParenExpr) Type() model.ValueType + func (node *ParenExpr) String() string + type ParseErr struct + Err error + Line int + Pos int + func (e *ParseErr) Error() string + type Pos int + type Query interface + Cancel func() + Exec func(ctx context.Context) *Result + Statement func() Statement + Stats func() *stats.TimerGroup + type Queryable interface + Querier func() (local.Querier, error) + type RecordStmt struct + Expr Expr + Labels model.LabelSet + Name string + func (node *RecordStmt) String() string + type Result struct + Err error + Value model.Value + func (r *Result) Matrix() (model.Matrix, error) + func (r *Result) Scalar() (*model.Scalar, error) + func (r *Result) String() string + func (r *Result) Vector() (model.Vector, error) + type Statement interface + type Statements []Statement + func ParseStmts(input string) (Statements, error) + func (stmts Statements) String() (s string) + type StringLiteral struct + Val string + func (e *StringLiteral) Type() model.ValueType + func (node *StringLiteral) String() string + type Test struct + func NewTest(t testutil.T, input string) (*Test, error) + func (t *Test) Close() + func (t *Test) Context() context.Context + func (t *Test) QueryEngine() *Engine + func (t *Test) Run() error + func (t *Test) Storage() local.Storage + type UnaryExpr struct + Expr Expr + Op itemType + func (e *UnaryExpr) Type() model.ValueType + func (node *UnaryExpr) String() string + type VectorMatchCardinality int + const CardManyToMany + const CardManyToOne + const CardOneToMany + const CardOneToOne + func (vmc VectorMatchCardinality) String() string + type VectorMatching struct + Card VectorMatchCardinality + Include model.LabelNames + MatchingLabels model.LabelNames + On bool + type VectorSelector struct + LabelMatchers metric.LabelMatchers + Name string + Offset time.Duration + func (e *VectorSelector) Type() model.ValueType + func (node *VectorSelector) String() string + type Visitor interface + Visit func(node Node) (w Visitor)