subscriber

package
Version: v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Nov 16, 2015 License: MIT, MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BalanceMode

type BalanceMode int
const (
	ALL BalanceMode = iota
	ANY
)

type Config

type Config struct {
	// Whether to enable to Subscriber service
	Enabled bool `toml:"enabled"`
}

func NewConfig

func NewConfig() Config

type PointsWriter

type PointsWriter interface {
	WritePoints(p *cluster.WritePointsRequest) error
}

type Service

type Service struct {
	MetaStore interface {
		Databases() ([]meta.DatabaseInfo, error)
		WaitForDataChanged() error
	}
	NewPointsWriter func(u url.URL) (PointsWriter, error)
	Logger          *log.Logger
	// contains filtered or unexported fields
}

The Subscriber service manages forking the incoming data from InfluxDB to defined third party destinations. Subscriptions are defined per database and retention policy.

func NewService

func NewService(c Config) *Service

func (*Service) Close

func (s *Service) Close() error

func (*Service) Open

func (s *Service) Open() error

func (*Service) Points

func (s *Service) Points() chan<- *cluster.WritePointsRequest

Return channel into which write point requests can be sent.

func (*Service) SetLogger added in v0.2.1

func (s *Service) SetLogger(l *log.Logger)

SetLogger sets the internal logger to the logger passed in.

func (*Service) Update

func (s *Service) Update() error

start new and stop deleted subscriptions.

type UDP

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

Writes points over UDP using the line protocol

func NewUDP

func NewUDP(addr string) *UDP

func (*UDP) WritePoints

func (u *UDP) WritePoints(p *cluster.WritePointsRequest) (err error)

Jump to

Keyboard shortcuts

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