README.md in sidekiq_prometheus-1.1.0 vs README.md in sidekiq_prometheus-1.2.0
- old
+ new
@@ -79,10 +79,11 @@
* `custom_labels`: Array of names for each label that will be passed during the reporting.
* `gc_metrics_enabled`: Boolean that determines whether to record object allocation metrics per job. The default is `true`. Setting this to `false` if you don't need this metric.
* `global_metrics_enabled`: Boolean that determines whether to report global metrics from the PeriodicMetrics reporter. When `true` this will report on a number of stats from the Sidekiq API for the cluster. This requires Sidekiq::Enterprise as the reporter uses the leader election functionality to ensure that only one worker per cluster is reporting metrics.
* `periodic_metrics_enabled`: Boolean that determines whether to run the periodic metrics reporter. `PeriodicMetrics` runs a separate thread that reports on global metrics (if enabled) as well worker GC stats (if enabled). It reports metrics on the interval defined by `periodic_reporting_interval`. Defaults to `true`.
* `periodic_reporting_interval`: interval in seconds for reporting periodic metrics. Default: `30`
+* `metrics_server_enabled`: Boolean that determines whether to run the rack server. Defaults to `true`
* `metrics_host`: Host on which the rack server will listen. Defaults to
`localhost`
* `metrics_port`: Port on which the rack server will listen. Defaults to `9359`
* `registry`: An instance of `Prometheus::Client::Registry`. If you have a registry with defined metrics you can use this option to pass in your registry.
@@ -92,10 +93,11 @@
config.custom_labels = [:worker_class, :job_type, :any_other_label]
config.gc_metrics_enabled = false
config.global_metrics_enabled = true
config.periodic_metrics_enabled = true
config.periodic_reporting_interval = 20
+ config.metrics_server_enabled = true
config.metrics_port = 8675
end
```
Custom labels may be added by defining the `prometheus_labels` method in the worker class,
@@ -243,17 +245,19 @@
See the [documentation of the Prometheus::Client library](https://github.com/prometheus/client_ruby) for all of the available options for setting metric values.
## Development
-After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake test` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
+After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
To install this gem onto your local machine, run `bundle exec rake install`.
## Contributors
* Lukas Eklund ([@leklund](https://github.com/leklund))
* NHM Tanveer Hossain Khan ([@we4tech](https://github.com/we4tech))
+* [@Postmodern](https://github.com/postmodern)
+* Ross Jones ([@rossjones](https://github.com/rossjones))
## Contributing
Bug reports and pull requests are welcome on GitHub at https://github.com/fastly/sidekiq-prometheus. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.