Rack-Mini-profiler – The Secret Weapon of Ruby and Rails Speed
nateberkopec.com
nateberkopec.com
It allowed us to quickly determine what pages were slowest and why, but also what pages were being hit the most by users. Sorting by 'agony' means: "This page is a combination of being hit the most, and the slowest. Take care of it pronto."
Amazingly, we started knocking out 'agony' problem areas, and our site is super quick now with minimal effort.
Here's an example of what their dashboard looks like:
Some other resources on rack-mini-profiler are:
https://samsaffron.com/archive/2013/03/19/flame-graphs-in-ru...
https://samsaffron.com/archive/2012/07/12/miniprofiler-ruby-...
Some history: https://samsaffron.com/archive/2011/06/09/+Profiling+your+we...
My talk, measuring Ruby https://www.youtube.com/watch?v=LWyEWUD-ztQ
And Off the Rails https://www.youtube.com/watch?v=aP5NNkzb4og
Great article, but there's no further mention about SSL. Specifically, why should I turn it off in the first place for this gem, and when/how can I turn it back on? Is there some special step(s) needed to do so, and what are they?
Oxymoron!
Wait... in production? Anyone can do this?
> rack-mini-profiler runs in the development environment by default in Rails apps. We're going to enable it in production, and hide it behind a URL parameter. You can also do things like make it visible only to admin users, etc.
> The best part - rack-mini-profiler is designed to be run in production. Yeah!
Then later:
> rack-mini-profiler is designed to be used in production.
It gave admins a clear picture of what is going on, all the time, and transformed the way we reasoned about performance.
rack-mini-profiler is a port, I use it in development and still predominantly in production!
The key is that ONLY and ONLY admins get access to the features, and we only do profiling for admins. To achieve this nothing is measured unless a request is explicitly authorized.
Very odd to hear this DDoS concern.