collector

command module
v0.0.0-...-9f3775e Latest Latest
Warning

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

Go to latest
Published: Oct 19, 2018 License: GPL-3.0 Imports: 16 Imported by: 0

README

Go Report Card Build Status GoDoc

Collector

Collector provides an API which:

  • Takes a golo.Output in json
  • Takes a database name from the request path
  • Pushes this information into a channel

This channel is, in a gofunc;

  • Consumed
  • Pushed to various storage locations

Currently we support influx, but adding new storage locations is very simple; the interface is:

type Collector interface {
    Push(OutputMapper) error
}

Usage

This project is best used with docker:

$ docker run goload/collector --help
Usage of /collector:
  -influx string
        influx host (default "http://localhost:8086")

The default options will point to influx on localhost, the flag -influx will change this.

Development

This project strives for high test coverage, and for happy and sad paths to be covered. Please do ensure pull requests have tests with them, where appropriate.

Building and testing can be done with either the standard docker toolchain:

$ go get -u
$ go test -v
$ go build

Or via the convenience wrappers in the Makefile

$ make test collector

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

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