Help us shape the future of Go! Take the 2026 Go Developer Survey

aggregate

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Aug 25, 2026 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Aggregator

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

func New

func New(options Options) *Aggregator

func (*Aggregator) Apply

func (*Aggregator) ApplyAt

func (a *Aggregator) ApplyAt(report domain.ReportEnvelope, receivedAt time.Time) (ApplyResult, error)

func (*Aggregator) Clone

func (a *Aggregator) Clone() (*Aggregator, error)

func (*Aggregator) HistoryMetadata

func (a *Aggregator) HistoryMetadata() domain.HistoryMetadata

func (*Aggregator) MarshalState

func (a *Aggregator) MarshalState() ([]byte, error)

func (*Aggregator) ReplaceWith

func (a *Aggregator) ReplaceWith(candidate *Aggregator) error

func (*Aggregator) RestoreState

func (a *Aggregator) RestoreState(payload []byte) error

func (*Aggregator) Snapshot

func (a *Aggregator) Snapshot() domain.Topology

func (*Aggregator) Subscribe

func (a *Aggregator) Subscribe() (<-chan struct{}, func())

type ApplyResult

type ApplyResult struct {
	Receipt               domain.ReportReceipt
	Traffic               []domain.AcceptedTraffic
	PathTransitions       []domain.PathTransition
	Changed               bool
	CanonicalStateChanged bool
}

type Options

type Options struct {
	HeartbeatInterval time.Duration
	ControlNodeIDs    []string
	Now               func() time.Time
	NewNodeID         func() string
}

Jump to

Keyboard shortcuts

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