trace

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Jan 31, 2025 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	OutputNewLine = "\n"
)

Output parameters for consistent formatting

Variables

This section is empty.

Functions

This section is empty.

Types

type Manager

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

func New

func New(sender interfaces.MessageSender, opts ...TraceManagerOption) *Manager

New creates a new TraceManager with options

func (*Manager) Done

func (t *Manager) Done() <-chan struct{}

Done returns a channel that is closed when tracing is complete

func (*Manager) GetNodes

func (t *Manager) GetNodes() []types.Node

GetNodes returns a copy of the current nodes

func (*Manager) Start

func (t *Manager) Start(ctx context.Context)

Start starts the trace manager

type TraceManagerOption

type TraceManagerOption func(*Manager)

TraceManagerOption defines a function type for configuring TraceManager

func WithConfig

func WithConfig(cfg *config.Config) TraceManagerOption

func WithIPProvider

func WithIPProvider(provider ipinfo.Provider) TraceManagerOption

WithIPProvider sets the IP info provider

Jump to

Keyboard shortcuts

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