/go-json-rest-middleware-statsd

Statsd Middleware for Go-Json-Rest

Primary LanguageGoMIT LicenseMIT

Statsd Middleware for Go-Json-Rest

Currently not used in production, API subject to change

godoc license

This is a middleware for Go-Json-Rest. It uses g2s to send statistics about the current request/response to a statsd server. It depends on rest.TimerMiddleware and rest.RecorderMiddleware that should be in the wrapped middlewares.

The two metrics are in the form:

  • [<Prefix>.]response.status_code.<StatusCode>: Counter.
  • [<Prefix>.]response.elasped_time: Timer.

Copyright (c) 2015-2016 Antoine Imbert

MIT License

Analytics