logging

package
v1.0.5 Latest Latest
Warning

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

Go to latest
Published: Nov 9, 2023 License: Apache-2.0, BSD-3-Clause Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNotFound = errors.New("stream: not found")

ErrNotFound is returned when the log does not exist.

Functions

This section is empty.

Types

type Handler

type Handler func(...*model.LogEntry)

Handler defines a callback function for handling log entries.

type Log

type Log interface {
	// Open opens the log.
	Open(c context.Context, stepID int64) error

	// Write writes the entry to the log.
	Write(c context.Context, stepID int64, entry *model.LogEntry) error

	// Tail tails the log.
	Tail(c context.Context, stepID int64, handler Handler) error

	// Close closes the log.
	Close(c context.Context, stepID int64) error
}

Log defines a log multiplexer.

func New

func New() Log

New returns a new logger.

Jump to

Keyboard shortcuts

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