statreporter

package
v1.6.0 Latest Latest
Warning

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

Go to latest
Published: Nov 10, 2014 License: Apache-2.0 Imports: 10 Imported by: 4 modules, 10 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Configure added in v1.6.0

func Configure(cfg *Config) error

Start runs a goroutine that periodically coalesces the collected statistics and reports them to statshub via HTTPS post

Types

type Config added in v1.6.0

type Config struct {
	// ReportingPeriod: how frequently to report
	ReportingPeriod time.Duration

	// StatshubAddr: the address of the statshub server to which to report
	StatshubAddr string

	// InstanceId: the instanceid under which to report
	InstanceId string
}

type DimGroup added in v1.6.0

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

DimGroup represents a group of dimensions for

func CountryDim added in v1.6.0

func CountryDim() *DimGroup

func Dim added in v1.6.0

func Dim(key string, value string) *DimGroup

Dim constructs a DimGroup starting with a single dimension.

func (*DimGroup) And added in v1.6.0

func (dg *DimGroup) And(key string, value string) *DimGroup

And creates a new DimGroup that adds the given dim to the existing ones in the group.

func (*DimGroup) Gauge added in v1.6.0

func (dg *DimGroup) Gauge(key string) *UpdateBuilder

func (*DimGroup) Increment added in v1.6.0

func (dg *DimGroup) Increment(key string) *UpdateBuilder

func (*DimGroup) String added in v1.6.0

func (dg *DimGroup) String() string

String returns a string representation of this DimGroup with keys in alphabetical order, making it suitable for using as a key representing this DimGroup.

func (*DimGroup) WithCountry added in v1.6.0

func (dg *DimGroup) WithCountry() *DimGroup

type UpdateBuilder

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

UpdateBuilder is an intermediary data structure used in preparing an update for submission to statreporter.

func (*UpdateBuilder) Add

func (b *UpdateBuilder) Add(val int64)

func (*UpdateBuilder) Set

func (b *UpdateBuilder) Set(val int64)

Jump to

Keyboard shortcuts

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