tracer

package
v0.35.1 Latest Latest
Warning

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

Go to latest
Published: Apr 9, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Collector

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

func NewCollector

func NewCollector() *Collector

func (*Collector) AddTrace

func (c *Collector) AddTrace(trace *enginev1.Trace)

func (*Collector) Enabled

func (c *Collector) Enabled() bool

func (*Collector) Traces

func (c *Collector) Traces() []*enginev1.Trace

type Context

type Context interface {
	StartAction(action string) Context
	StartConditionAll() Context
	StartConditionAny() Context
	StartConditionNone() Context
	StartCondition() Context
	StartDerivedRole(name string) Context
	StartExpr(expr string) Context
	StartNthCondition(index int) Context
	StartPolicy(name string) Context
	StartResource(kind string) Context
	StartRule(name string) Context
	StartScope(scope string) Context
	StartVariable(name, expr string) Context
	StartVariables() Context
	StartOutput(ruleName string) Context
	Activated()
	AppliedEffect(effect effectv1.Effect, message string)
	ComputedBoolResult(result bool, err error, message string)
	ComputedOutput(output *enginev1.OutputEntry)
	ComputedResult(result any)
	Failed(err error, message string)
	Skipped(err error, message string)
}

func Start

func Start(sink Sink) Context

type Sink

type Sink interface {
	Enabled() bool
	AddTrace(trace *enginev1.Trace)
}

type ZapSink

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

func NewZapSink

func NewZapSink(log *zap.Logger) *ZapSink

func (*ZapSink) AddTrace

func (zs *ZapSink) AddTrace(trace *enginev1.Trace)

func (*ZapSink) Enabled

func (zs *ZapSink) Enabled() bool

Jump to

Keyboard shortcuts

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