Home

Awesome

Garelic: Use Google Analytics as "New Relic" performance monitoring for your Rails app

This gem uses Google Analytics User Timing API to report application performance statistics directly to Google Analytics, where you can slice & dice your data as you wish.

Here are some features with pictures:

Or look at these slides from a Garelic presentation.

Installation

It's easy as 1-2-3.

Step 1. Add this line to your application's Gemfile:

gem 'garelic'

Step 2. Add <%= Garelic.monitoring 'UA-XXXXXX-X' %> instrumentation in application layout template (before the closing </head> tag) like this:

<head>
    <!-- other rails stuff -->
    <%= Garelic.monitoring 'UA-XXXXXX-X' %>
    <!-- make sure you remove your old GA code! -->
</head>

Step 3. Go to Google Analytics > Content > Site Speed > User Timings

Enjoy!

Known advantages

Known drawbacks

TODO

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Added some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request