relabeler

package
v0.2.10 Latest Latest
Warning

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

Go to latest
Published: May 2, 2018 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 MessageWriter

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

MessageWriter is a message writer implementatino for the Relabeler sink

func (*MessageWriter) Close

func (o *MessageWriter) Close() error

Close implements Close() for the relabeler MessageWriter

func (*MessageWriter) WriteMessage

func (o *MessageWriter) WriteMessage(ctx context.Context, m *logspray.Message) error

WriteMessage implements the MessageWriter interface for the relabeler sink

type Relabeler

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

Relabeler is a sink that runs all new messages through a set of relabel rules.

func New

func New(nextSink sinks.Sinker, instRules, lineRules *relabel.Config) *Relabeler

New creates a new Relabeler

func (*Relabeler) AddSource

func (o *Relabeler) AddSource(id string, Labels map[string]string) (sinks.MessageWriter, error)

AddSource implemets sink.Sinker for the Relabeler sink

Jump to

Keyboard shortcuts

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