carbon

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jul 30, 2020 License: AGPL-3.0 Imports: 16 Imported by: 5

Documentation

Overview

package carbon provides a traditional carbon input for metrictank note: it does not support the "carbon2.0" protocol that serializes metrics2.0 into a plaintext carbon-like protocol

Index

Constants

This section is empty.

Variables

View Source
var Enabled bool

Functions

func ConfigProcess

func ConfigProcess()

func ConfigSetup

func ConfigSetup()

Types

type Carbon

type Carbon struct {
	input.Handler
	// contains filtered or unexported fields
}

func New

func New() *Carbon

func (*Carbon) ExplainPriority

func (c *Carbon) ExplainPriority() interface{}

func (*Carbon) IntervalGetter

func (c *Carbon) IntervalGetter(i IntervalGetter)

func (*Carbon) MaintainPriority

func (c *Carbon) MaintainPriority()

MaintainPriority is very simplistic for carbon. there is no backfill, so mark as ready immediately.

func (*Carbon) Name

func (c *Carbon) Name() string

func (*Carbon) Start

func (c *Carbon) Start(handler input.Handler, cancel context.CancelFunc) error

func (*Carbon) Stop

func (c *Carbon) Stop()

type ConnTrack

type ConnTrack struct {
	sync.Mutex
	// contains filtered or unexported fields
}

func NewConnTrack

func NewConnTrack() *ConnTrack

func (*ConnTrack) Add

func (c *ConnTrack) Add(conn net.Conn)

func (*ConnTrack) CloseAll

func (c *ConnTrack) CloseAll()

func (*ConnTrack) Remove

func (c *ConnTrack) Remove(conn net.Conn)

type IndexIntervalGetter

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

func (IndexIntervalGetter) GetInterval

func (i IndexIntervalGetter) GetInterval(name string) int

type IntervalGetter

type IntervalGetter interface {
	GetInterval(name string) int
}

IntervalGetter is anything that can return the interval for the given path we don't want the carbon plugin to directly talk to an index because the api surface is too big and it would couple too tightly which is annoying in unit tests

func NewIndexIntervalGetter

func NewIndexIntervalGetter(idx idx.MetricIndex) IntervalGetter

Jump to

Keyboard shortcuts

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