channel

package
v0.0.0-...-cedfd68 Latest Latest
Warning

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

Go to latest
Published: Nov 27, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Tailer

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

Tailer consumes and processes a channel of strings, and sends them to a stream of log messages.

This tailer attaches the tags from source.Config.ChannelTags to each message, in addition to the origin tags and tags in source.Config.Tags.

func NewTailer

func NewTailer(source *sources.LogSource, inputChan chan *config.ChannelMessage, outputChan chan *message.Message) *Tailer

NewTailer returns a new Tailer

func (*Tailer) Start

func (t *Tailer) Start()

Start starts the tailer.

func (*Tailer) WaitFlush

func (t *Tailer) WaitFlush()

WaitFlush waits for all items in the input channel to be processed. In the process, this closes the input channel. Any subsequent sends to the channel will fail.

Jump to

Keyboard shortcuts

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