abel

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Nov 11, 2018 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CurrentAggregateWindow

func CurrentAggregateWindow(granularity int64, now time.Time) int64

CurrentAggregateWindow returns the current timestamp (in millis) at which the aggregate is happening

func NextAggregateWindow

func NextAggregateWindow(granularity int64, now time.Time) int64

NextAggregateWindow returns the next timestamp at which the aggregate will happen

func PreviousAggregateWindow

func PreviousAggregateWindow(granularity int64, now time.Time) int64

PreviousAggregateWindow returns the previous timestamp (in millis) at which the aggregate happened

func TimeToNextAggregateWindow

func TimeToNextAggregateWindow(granularity int64, now time.Time) time.Duration

TimeToNextAggregateWindow returns the duration to next aggregate given now as the current time

Types

type Abel

type Abel struct {
	Url string
}

Abel is the client used to contact Abel to query for the required metrics

func (*Abel) Get

func (w *Abel) Get(metric string, tags []string) (int64, jsonparser.ValueType, error)

Get the count of the metric associated with it's tags

func (*Abel) GetCount

func (w *Abel) GetCount(metric string, tags []string, start int64, end int64, duration int64) (int64, jsonparser.ValueType, error)

GetCount gets the count of the metric associated with it's tags. We can filter the responses by further start & end. We can also define the window of aggregation using the duration parameter.

Jump to

Keyboard shortcuts

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