observer

package
v0.0.0-...-c864ae1 Latest Latest
Warning

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

Go to latest
Published: Apr 13, 2023 License: BSD-2-Clause, BSD-3-Clause, MIT Imports: 8 Imported by: 0

Documentation

Overview

observer package contains Reporting implementations that capture annealing events and log them to various destinations in potentially very different formats (as dictated by loggers passed to a logger at build-time)

Index

Constants

View Source
const AnnealingLogLevel logging.Level = "Annealing"

Variables

This section is empty.

Functions

This section is empty.

Types

type AnnealingAttributeObserver

type AnnealingAttributeObserver struct {
	AnnealingObserver
}

AnnealingAttributeObserver produces a relevant set of Attributes to match any AnnealingEvents received and passes those events to its Logger for whatever observer is appropriate.

func (*AnnealingAttributeObserver) ObserveEvent

func (aao *AnnealingAttributeObserver) ObserveEvent(event observer.Event)

ObserveEvent captures and converts Event instances into a Attributes instance that captures key attributes associated with the event, and passes them to the Logger for processing.

func (*AnnealingAttributeObserver) WithFilter

func (*AnnealingAttributeObserver) WithLogHandler

type AnnealingInvariantObserver

type AnnealingInvariantObserver struct {
	AnnealingObserver
	// contains filtered or unexported fields
}

func (*AnnealingInvariantObserver) ObserveEvent

func (amo *AnnealingInvariantObserver) ObserveEvent(event observer.Event)

func (*AnnealingInvariantObserver) WithFilter

func (*AnnealingInvariantObserver) WithLogHandler

type AnnealingMessageObserver

type AnnealingMessageObserver struct {
	AnnealingObserver
	// contains filtered or unexported fields
}

AnnealingMessageObserver produces a stream of human-friendly, free-form text log entries from any observed Event instances received.

func (*AnnealingMessageObserver) ObserveEvent

func (amo *AnnealingMessageObserver) ObserveEvent(event observer.Event)

ObserveEvent captures and converts Event instances into free-form text strings that it then passes onto its relevant Logger as an Info call.

func (*AnnealingMessageObserver) WithFilter

func (*AnnealingMessageObserver) WithLogHandler

func (amo *AnnealingMessageObserver) WithLogHandler(handler logging.Logger) *AnnealingMessageObserver

func (*AnnealingMessageObserver) WithLoopInvariantObserver

func (amo *AnnealingMessageObserver) WithLoopInvariantObserver(watchLoopInvariant bool) *AnnealingMessageObserver

type AnnealingObserver

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

AnnealingObserver is a base-implementation of an annealing logger. It has a logHandler, but deliberately drops any AnnealingEvents received.

func (*AnnealingObserver) ObserveAnnealingEvent

func (l *AnnealingObserver) ObserveAnnealingEvent(event observer.Event)

Allows for the receipt of Event instances, but deliberately takes no action in observer those events.

Directories

Path Synopsis
modulators package supplies a number of observer modulators for managing the chattiness of loggers.
modulators package supplies a number of observer modulators for managing the chattiness of loggers.

Jump to

Keyboard shortcuts

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