collector

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: Mar 17, 2025 License: AGPL-3.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewExecutionError

func NewExecutionError(err error, executionId string) error

Types

type AwaitingCompactionMsg

type AwaitingCompactionMsg struct{}

type CollectionFinishedMsg

type CollectionFinishedMsg struct{}

type Collector

type Collector struct {
	Events chan *proto.Event
	// contains filtered or unexported fields
}

func New

func New(pluginManager *plugin_manager.PluginManager, partition *config.Partition, cancel context.CancelFunc) (*Collector, error)

func (*Collector) Close

func (c *Collector) Close()

func (*Collector) Collect

func (c *Collector) Collect(ctx context.Context, fromTime time.Time) error

func (*Collector) Compact

func (c *Collector) Compact(ctx context.Context) error

func (*Collector) Errors

func (c *Collector) Errors() []string

func (*Collector) Notify

func (c *Collector) Notify(event *proto.Event)

Notify implements observer.Observer send an event down the channel to be picked up by the handlePluginEvent goroutine

func (*Collector) StatusString

func (c *Collector) StatusString() string

func (*Collector) WaitForCompletion

func (c *Collector) WaitForCompletion(ctx context.Context) error

WaitForCompletion waits for our execution to have state ExecutionState_COMPLETE

type CompactionStatusUpdateMsg

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

type ExecutionError

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

func (ExecutionError) Error

func (e ExecutionError) Error() string

func (*ExecutionError) Unwrap

func (e *ExecutionError) Unwrap() error

Unwrap implements error wrapping.

type ExecutionState

type ExecutionState int

enum of execution states

const (
	ExecutionState_PENDING ExecutionState = iota
	ExecutionState_STARTED ExecutionState = iota
	ExecutionState_COMPLETE
	ExecutionState_ERROR
)

Jump to

Keyboard shortcuts

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