out_forward

package
v0.0.0-...-ab997d7 Latest Latest
Warning

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

Go to latest
Published: Oct 8, 2015 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Factory

func Factory() plugin.Plugin

Types

type AutoConnectWriter

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

func NewAutoConnectWriter

func NewAutoConnectWriter(f ConnectFunc, seq sequencer, ackTimeout time.Duration) *AutoConnectWriter

func (*AutoConnectWriter) Close

func (w *AutoConnectWriter) Close()

func (*AutoConnectWriter) Write

func (w *AutoConnectWriter) Write(b []byte) (n int, err error)

type CompatibleMode

type CompatibleMode int
const (
	CompatibleDisable CompatibleMode = iota
	CompatibleLegacy
	CompatibleExtend
)

func (*CompatibleMode) UnmarshalText

func (m *CompatibleMode) UnmarshalText(b []byte) (err error)

type Config

type Config struct {
	MinWeight  int             `toml:"min_weight"`
	Compatible CompatibleMode  `toml:"compatible"`
	AckTimeout buffer.Duration `toml:"ack_timeout"`
	Servers    []struct {
		Server string `toml:"server"`
		Weight int    `toml:"weight"`
	} `toml:"servers"`
}

type ConnectFunc

type ConnectFunc func() (net.Conn, error)

type ForwardOutput

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

func (*ForwardOutput) Close

func (o *ForwardOutput) Close() error

func (*ForwardOutput) Encode

func (o *ForwardOutput) Encode(ev *message.Event) (buffer.Sizer, error)

func (*ForwardOutput) Init

func (o *ForwardOutput) Init(env *plugin.Env) (err error)

func (*ForwardOutput) Start

func (o *ForwardOutput) Start() (err error)

func (*ForwardOutput) Write

func (o *ForwardOutput) Write(l []buffer.Sizer) (int, error)

type RoundRobinWriter

type RoundRobinWriter struct {
	ErrorC chan error
	// contains filtered or unexported fields
}

func NewRoundRobinWriter

func NewRoundRobinWriter(minWeight int) *RoundRobinWriter

func (*RoundRobinWriter) Add

func (w *RoundRobinWriter) Add(writer io.Writer, weight int)

func (*RoundRobinWriter) Write

func (w *RoundRobinWriter) Write(b []byte) (n int, err error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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