Sha256: d483108e4305d17ae7c943bd1bdf5fd6643f35d68d8c9e290cc56fe759f9e9e5
Contents?: true
Size: 804 Bytes
Versions: 1
Compression:
Stored size: 804 Bytes
Contents
# Custom Prometheus Ruby Client This repo is essentially a fork of https://github.com/prometheus/client_ruby and adds the following behaviour to the captured metrics. - It takes the service_name as an options to the rake middleware (see usage) - It adds the following labels to the metrics * User Agent * Accept * Content Type ## Usage Add the following to your Gemfile ``` gem 'custom-prometheus-client' ``` Then in your config.ru add the following (Change 'my_app' to the name of your app being monitored) ``` require 'prometheus/client/rack/collector' require 'prometheus/client/rack/exporter' options = { service_name: 'my_app'} use Prometheus::Client::Rack::Collector, options use Prometheus::Client::Rack::Exporter ``` Configure your prometheus.yml to scrape /metrics from rails service
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
custom-prometheus-client-0.4.3 | README.md |