model

package
v0.2.5 Latest Latest
Warning

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

Go to latest
Published: Nov 22, 2023 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const ValueTypeLog parser.ValueType = "log"
View Source
const ValueTypeLogSelector parser.ValueType = "logselector"

Variables

This section is empty.

Functions

This section is empty.

Types

type ErrQueryCanceled

type ErrQueryCanceled string

ErrQueryCanceled is returned if a query was canceled during processing.

func (ErrQueryCanceled) Error

func (e ErrQueryCanceled) Error() string

type ErrQueryTimeout

type ErrQueryTimeout string

ErrQueryTimeout is returned if a query timed out during processing.

func (ErrQueryTimeout) Error

func (e ErrQueryTimeout) Error() string

type ErrStorage

type ErrStorage struct{ Err error }

ErrStorage is returned if an error was encountered in the storage layer during query handling.

func (ErrStorage) Error

func (e ErrStorage) Error() string

type ErrTooManySamples

type ErrTooManySamples string

ErrTooManySamples is returned if a query would load more than the maximum allowed samples into memory.

func (ErrTooManySamples) Error

func (e ErrTooManySamples) Error() string

type ErrWithWarnings

type ErrWithWarnings struct {
	Err      error
	Warnings Warnings
}

type LineMatcher

type LineMatcher struct {
	Op    parser.ItemType
	Value string
}

type Log

type Log struct {
	Name  string
	Lines []LogLine
}

func (Log) String

func (l Log) String() string

func (Log) Type

func (l Log) Type() parser.ValueType

type LogLine

type LogLine interface {
	String() string
}

type LogSelector

type LogSelector struct {
	Name          string
	LabelMatchers []*labels.Matcher
	LineMatchers  []*LineMatcher
	TimeRange     TimeRange
}

LogSelector represents a Log selection.

func (LogSelector) PositionRange

func (ls LogSelector) PositionRange() parser.PositionRange

func (LogSelector) Pretty

func (ls LogSelector) Pretty(int) string

func (LogSelector) PromQLExpr

func (ls LogSelector) PromQLExpr()

implements parser.Expr

func (LogSelector) String

func (ls LogSelector) String() string

func (LogSelector) Type

func (ls LogSelector) Type() parser.ValueType

implements parser.Value

type TimeRange

type TimeRange struct {
	Start time.Time
	End   time.Time
}

type Warnings

type Warnings []error

Jump to

Keyboard shortcuts

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