This add-on is operated by Restful Labs LLC
Big data for developers
Table of Contents
RESTful Metrics is a business intelligence tool built for developers. You add some hooks within your application and you can instantly begin reporting on those metrics.
Deploying to Heroku
To use RESTful Metrics on Heroku, install the addon:
$ heroku addons:add restful_metrics
To use the Ruby client, add the gem to your Gemfile:
If you’d prefer to use the REST interface, see our docs on using RESTful Metrics via REST.
An application identifier is automatically created for you using your Heroku App ID. If you do not know your Heroku App ID or you’d like to create a custom one, visit the addon’s admin panel. You can find more information about application identifiers here.
Obtain the API key that was assigned to you when you added the RESTful Metrics addon:
$ heroku config
Your API key will be the Heroku environment variable:
If you’re using the Ruby client, you’ll want to initialize the client settings when your application loads. If you have a Rails application, this is best done with an initializer stored in
If you’re application has a worker, the Ruby client can automatically send data points asychronously by adding this to your initializer:
RestfulMetrics::Client.async = true
To send metric data points, use these hooks throughout your application:
RestfulMetrics::Client.add_metric(<application_identifier>, <metric_name>, <metric_value>)
To send compound metric data points:
RestfulMetrics::Client.add_compound_metric(<application_identifier>, <compound_metric_name>, <compound_metric_value>)
The Ruby client will automatically skip sending data points when you’re application is not being run in a production environment.