downsample

package
v0.4.1 Latest Latest
Warning

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

Go to latest
Published: Aug 27, 2018 License: Apache-2.0 Imports: 43 Imported by: 8

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Downsampler

type Downsampler interface {
	NewMetricsAppender() MetricsAppender
}

Downsampler is a downsampler.

func NewDownsampler

func NewDownsampler(
	opts DownsamplerOptions,
) (Downsampler, error)

NewDownsampler returns a new downsampler.

type DownsamplerOptions

type DownsamplerOptions struct {
	Storage                 storage.Storage
	StorageFlushConcurrency int
	RulesKVStore            kv.Store
	NameTag                 string
	ClockOptions            clock.Options
	InstrumentOptions       instrument.Options
	TagEncoderOptions       serialize.TagEncoderOptions
	TagDecoderOptions       serialize.TagDecoderOptions
	TagEncoderPoolOptions   pool.ObjectPoolOptions
	TagDecoderPoolOptions   pool.ObjectPoolOptions
	OpenTimeout             time.Duration
}

DownsamplerOptions is a set of required downsampler options.

type MetricsAppender

type MetricsAppender interface {
	AddTag(name, value string)
	SamplesAppender() (SamplesAppender, error)
	Reset()
	Finalize()
}

MetricsAppender is a metrics appender that can build a samples appender, only valid to use with a single caller at a time.

type SamplesAppender

type SamplesAppender interface {
	AppendCounterSample(value int64) error
	AppendGaugeSample(value float64) error
}

SamplesAppender is a downsampling samples appender, that can only be called by a single caller at a time.

Jump to

Keyboard shortcuts

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