#161 Three Profiling Tools
May 11, 2009 | 7 minutes | Performance, Tools
Ever want to know what Rails is doing under the hood during a request? In this episode I show three different profiling tools: New Relic RPM, FiveRuns TuneUp, and Rack::Bug.
- Download:
- source code
- mp4
- m4v
- webm
- ogv
Always look forward to your screen cast every Monday morning! Keep it up!
RPM is available as a gem as well, at least for production mode.
Yeahhh, monday! I so waited this moment. ;-) An another great and useful screencast, thank you! Ryan for the win! :-)
Comfirmed. You can use it as a gem in development too.
Ryan, I would love to hear which one of these tools you like the best, and which one you use (if any).
@Tim, I don't use any of these on a day-to-day basis, but I will boot one up occasionally when I need to figure out what Rails is doing.
Most often this is NewRelic's because it is most convenient if you are already using it for production too. But I am very intrigued by the other two, especially Rack::Bug which offers a boat-load of useful information and is extendable.
It seems that every time I have tried to integrate Five Runs into my application, I always get buggy results. This time I can view the drop down information, but there is now way for me to delve in deeper into the models and queries. I think the latest may only be useful for Rails 2.3.2 and not older. I'm running 2.2.2.
Great screencast though, Ryan! I wish I could have made it to Railsconf so I could have met you in person.
Good news! Rails resources increasing! We got another site that posts podcast and video tutorials online! Just to let you all know this.. Please visit http://www.buildingwebapps.com/podcasts
We should really support these initiatives. Thanks Ryan and thanks Michael Slater/Christopher Haupt from LearningRails. You guys are doing a great job. Keep it up!
Very cool. Thanks a bunch Ryan!
You may want to note that rack bug only works with Rails 2.3 or later. I tried on 2.1 and 2.2 and doesn't work because there is no ActionController::Dispatcher
The relic plugin isn't available at the momement
script/plugin install http://newrelic.rubyforge.org/svn/newrelic_rpm
.
.
.
+ ./lib/new_relic/config/ruby.rb
Plugin not found: ["http://newrelic.rubyforge.org/svn/newrelic_rpm"]
What is the best choice in production mode new_relic or 5runs?
And how can I profile actions which are called with Ajax?
Hey Ryan, nice cast!
Got a off-topic question. What do you use to syntax-highlight your code snippets in the show notes?
I was looking around and couldn't find a good one.
Thanks!
Thank you Ryan for your great efforts ;-)
new_relic requires that you give them your email address and then they give you a config file. Otherwise you can't use it.
Tune-up on Ubuntu doesn't work well because it creates files that require root access. I've been unable to find the correct chmod to resolve this problem as it seems to create some files each time at start-up.
Thanks for your railscast, Ryan! Nice compilation. I use mostly NewRelic for staging and production environments, and MySQL Query Reviewer for development mode:
http://flouri.sh/2008/4/10/mysql-query-reviewer-now-with-ajax-and-profiling
I find this last one really helpful and unobstrusive. You just put it in your app, no config files, and it will show a tiny floating div you can unfold to get more details of the queries, with helpful tips to get a better performance on them. Only works with MySQL, though.
Very cool stuff, thanks Ryan.
and what about security when using newrelic? everybody can see my logs. am i right? :)
Thanks Ryan. Good job.
Thanks, Ryan. Very interesting episode (as usual). You're saving me a lot of time searching new rails gems/plugins.
Getting "Plugin not found" when running "ruby script/plugin install http://newrelic.rubyforge.org/svn/newrelic_rpm", why is that? :S
TuneUp link doesn't work anymore. Are they out of business or something?
Now I'm wondering if action caching will work with pagination. I tried a couple of different things but I can't seem to get it to work. I was just wondering before I go to a lot of recoding on my existing blog to add this.
Installing rack-bug on rails 3:
http://rahul100885.blogspot.com/2011/04/configure-rack-bug-for-rails-3.html
an update on this would be greate! :)
This episode could sure use an update.
so... is it just me or did anyone else see subliminal message flashing at about 6:25?
An update on profiling a rails app would be great
+1 on this request