letheql

package
v0.2.0-alpha.2 Latest Latest
Warning

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

Go to latest
Published: Apr 24, 2023 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Engine added in v0.2.0

type Engine struct {
}

type Label

type Label struct {
	Key   string
	Value string
}

type Leaf

type Leaf struct {
	LeafType     LeafType
	LogRequest   LogRequest
	ScalarResult float64
	LogsResult   []logStore.LogLine
	Function     string
	TimeRange    TimeRange
	Keyword      string
}

type LeafType

type LeafType string
const (
	LeafTypeAuditLogRequest LeafType = "AuditLogRequest"
	LeafTypeEventLogRequest LeafType = "EventLogRequest"
	LeafTypeNodeLogRequest  LeafType = "NodeLogRequest"
	LeafTypePodLogRequest   LeafType = "PodLogRequest"
)
const (
	LeafTypeScalarResult LeafType = "ScalarResult"
	LeafTypeLogsResult   LeafType = "LogsResult"
)

type LogRequest

type LogRequest struct {
	// AuditSearchParams logs.AuditSearchParams
	EventSearchParams logStore.EventSearchParams
	NodeSearchParams  logStore.NodeSearchParams
	PodSearchParams   logStore.PodSearchParams
	DurationSeconds   int
	Function          string
}

type ParsedQuery

type ParsedQuery struct {
	Type    string
	Labels  []Label
	Keyword string
}

type Query added in v0.2.0

type Query interface {
	Exec() []string
}

type QueryData

type QueryData struct {
	ResultType ValueType          `json:"resultType"`
	Logs       []logStore.LogLine `json:"logs,omitempty"`
	Scalar     float64            `json:"scalar,omitempty"`
}

func ProcQuery

func ProcQuery(queryString string, timeRange TimeRange) (QueryData, error)

type TimeRange

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

type ValueType

type ValueType string
const (
	ValueTypeScalar ValueType = "scalar"
	ValueTypeLogs   ValueType = "logs"
)

Jump to

Keyboard shortcuts

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