libratopublisher

package
v0.0.0-...-b9af62b Latest Latest
Warning

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

Go to latest
Published: Feb 12, 2017 License: MIT Imports: 5 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Publisher

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

Publisher implements the canary.Publisher interface and is our means of ingesting canary.Measurements and converting them to Librato metrics.

func New

func New(user, token, source string) (p *Publisher)

New takes a user, token and source and return a pointer to a Publisher.

func NewFromEnv

func NewFromEnv() (*Publisher, error)

NewFromEnv is a convenience func that wraps New, and populates the required arguments via environment variables. If required variables cannot be found, errors are returned.

func (*Publisher) Publish

func (p *Publisher) Publish(m sensor.Measurement) (err error)

Publish takes a canary.Measurement and delivers it to the aggregator.

Jump to

Keyboard shortcuts

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