statsdurl

package module
v0.0.0-...-0dbc432 Latest Latest
Warning

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

Go to latest
Published: Oct 7, 2014 License: MIT Imports: 5 Imported by: 0

README

go-statsdurl

Connect to a database using a STATSD_URL.

Usage

It uses Statsd under the hood:

import "github.com/josegonzalez/go-statsdurl"

// Connect using os.Getenv("STATSD_URL").
c, err := statsdurl.Connect()

// Alternatively, connect using a custom Database URL.
c, err := statsdurl.ConnectToURL("udp://...")

In both cases you will get the result values of calling statsd.NewStatsdClient(...), that is, an instance of statsd.StatsdClient and an error.

Installation

Install it using the "go get" command:

go get github.com/josegonzalez/go-statsdurl

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Connect

func Connect() (*statsd.StatsdClient, error)

func ConnectToURL

func ConnectToURL(s string) (c *statsd.StatsdClient, err error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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