Skip to content
This repository


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

HTTP service for submitting metrics to Graphite

tree: 656444f93c

Fetching latest commit…


Cannot retrieve the latest commit at this time

Octocat-spinner-32 config
Octocat-spinner-32 lib
Octocat-spinner-32 spec
Octocat-spinner-32 .gitignore initial import May 30, 2012
Octocat-spinner-32 .rspec time to start fleshing out some tests here August 28, 2012
Octocat-spinner-32 Gemfile
Octocat-spinner-32 Gemfile.lock
Octocat-spinner-32 LICENSE initial import May 30, 2012
Octocat-spinner-32 Procfile initial import May 30, 2012


Backstop is a simple endpoint for submitting metrics to Graphite. It accepts JSON data via HTTP POST and proxies the data to one or more Carbon/Graphite listeners.


Collectd Metrics

Backstop supports submission of metrics via the Collectd write_http output plugin. A sample client configuration:

<Plugin write_http>
  <URL "">
    Format "JSON"
    User ""
    Password ""

GitHub Post-Receive Hooks

Backstop can receive commit data from GitHub post-receive webhooks. Your WebHook URL should consist of the Backstop service URL with the /github endpoint. For example,

All GitHub commit metrics contain the project name, branch information, author email and commit identifier, and are stored with a value of 1. These can then be visualized as annotation-style metrics using Graphite's drawAsFinite() function. Sample metric:

github.project.refs.heads.master.bob-example-com.10af2cb02eadd4cb1a3e43aa9cae47ef2cd07016 1 1203116237

Custom Metrics

Use the /publish endpoint in conjunction with one of the approved PREFIXES for submitting metrics to Backstop. In most environments it makes sense to use distinct prefixes for normal (e.g. gauge, counters, etc) metrics vs annotation (event-style) metrics.

Sending Metrics

Here is a basic example for posting an application metric to the custom prefix."",
   [{:metric => key, :value => value, :measure_time =>}].to_json)

Sending Annotations

Here is an example for posting a software release announcement to the note prefix."",
   [{:metric => "foobar.release", :value => "v214", :measure_time =>}].to_json)



$ export CARBON_URLS=...
$ export PREFIXES=...
$ foreman start


$ heroku create -s cedar
$ heroku config:add CARBON_URLS=...
$ heroku config:add PREFIXES=...
$ git push heroku master


Backstop is distributed under a 3-clause BSD license.


Thanks to Michael Gorsuch (@gorsuch) for his work on the collectd parser and the "Mitt" application that preceded Backstop.

Something went wrong with that request. Please try again.