correlator

package
v0.0.0-...-4fb4148 Latest Latest
Warning

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

Go to latest
Published: Jun 1, 2022 License: Apache-2.0 Imports: 14 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Sources Sources
}

func ParseConfig

func ParseConfig(b []byte) (Config, error)

func ParseConfigFromFile

func ParseConfigFromFile(cfgFile string) (Config, error)

type Correlation

type Correlation struct {
	Error       error `json:",omitempty"`
	Description string
	URL         string
}

type Correlator

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

func New

func New(cfg Config, logger log.Logger) (*Correlator, error)

func (*Correlator) Correlate

func (c *Correlator) Correlate(ctx context.Context, input Input) (d []Discovery, corr []Correlation, _ error)

Correlate provides correlations from the best effort input. NOTE: ARTIFICIAL INTELLIGENCE - USE WITH CARE! TODO(bwplotka): Make it a streaming response. TODO(bwplotka): Compose it better, it's currently a too long function with hardcoded elements for demo purposes.

type Discovery

type Discovery string

type Input

type Input struct {
	AlertName      string
	IgnoreExemplar bool
}

type JaegerSource

type JaegerSource struct {
	Source
}

type LokiSource

type LokiSource struct {
	Source
	UISource Source
}

type ParcaSource

type ParcaSource struct {
	Source
}

type Source

type Source struct {
	Version          string
	InternalEndpoint string
	ExternalEndpoint string
}

type Sources

type Sources struct {
	Thanos ThanosSource
	Loki   LokiSource
	Jaeger JaegerSource
	Parca  ParcaSource
}

type ThanosSource

type ThanosSource struct {
	Source
}

Jump to

Keyboard shortcuts

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