receiver

package
v0.7.1 Latest Latest
Warning

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

Go to latest
Published: Apr 5, 2016 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type TCP

type TCP struct {
	helper.Stoppable
	// contains filtered or unexported fields
}

TCP receive metrics from TCP connections

func NewPickle

func NewPickle(out chan *points.Points) *TCP

NewPickle create new instance of TCP with pickle listener enabled

func NewTCP

func NewTCP(out chan *points.Points) *TCP

NewTCP create new instance of TCP

func (*TCP) Addr

func (rcv *TCP) Addr() net.Addr

Addr returns binded socket address. For bind port 0 in tests

func (*TCP) Listen

func (rcv *TCP) Listen(addr *net.TCPAddr) error

Listen bind port. Receive messages and send to out channel

func (*TCP) SetGraphPrefix

func (rcv *TCP) SetGraphPrefix(prefix string)

SetGraphPrefix for internal cache metrics

func (*TCP) SetMaxPickleMessageSize added in v0.7.1

func (rcv *TCP) SetMaxPickleMessageSize(newSize uint32)

SetMaxPickleMessageSize sets maxPickleMessageSize (in bytes)

func (*TCP) SetMetricInterval added in v0.7.1

func (rcv *TCP) SetMetricInterval(interval time.Duration)

SetMetricInterval sets doChekpoint interval

func (*TCP) Stat

func (rcv *TCP) Stat(metric string, value float64)

Stat sends internal statistics to cache

type UDP

type UDP struct {
	helper.Stoppable
	// contains filtered or unexported fields
}

UDP receive metrics from UDP socket

func NewUDP

func NewUDP(out chan *points.Points) *UDP

NewUDP create new instance of UDP

func (*UDP) Addr

func (rcv *UDP) Addr() net.Addr

Addr returns binded socket address. For bind port 0 in tests

func (*UDP) Listen

func (rcv *UDP) Listen(addr *net.UDPAddr) error

Listen bind port. Receive messages and send to out channel

func (*UDP) SetGraphPrefix

func (rcv *UDP) SetGraphPrefix(prefix string)

SetGraphPrefix for internal cache metrics

func (*UDP) SetLogIncomplete added in v0.5.0

func (rcv *UDP) SetLogIncomplete(value bool)

SetLogIncomplete enable or disable incomplete messages logging

func (*UDP) SetMetricInterval added in v0.7.1

func (rcv *UDP) SetMetricInterval(interval time.Duration)

SetMetricInterval sets doChekpoint interval

func (*UDP) Stat

func (rcv *UDP) Stat(metric string, value float64)

Stat sends internal statistics to cache

Jump to

Keyboard shortcuts

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