How to Detect and Fix Slow Rails Requests
Derek Haynes has written "4 Simple Steps to Detect & Fix Slow Rails Requests," an excellent guide to figuring out what's causing your Rails app to slow down, and what to do about it. The main argument is that Rails itself is not usually to blame, but instead ancillary things like database access, CPU load, memory leaks, and the like. Naturally, the solution partly involves Derek's app, Scout, but separate from this, the article and ensuing discussion in the comments are very good.
Separately, query-reviewer, a project hosted on Google Code, is a Rails plugin that analyzes the SQL queries your Rails application generates and outputs warnings directly into your pages (for development use, naturally).
This post is sponsored by KickStart Events — RubyOnRails Training at the EMCC (East Midlands Conference Centre), UK. High-quality hands-on workshops and courses for web application developers. Taught by experienced mentors using live coding sessions, slides and participatory discussion.
August 5th, 2008 at 5:42 pm
Great article! I've installed query-reviewer and learned a lot about the bottlenecks on some of my apps.
August 5th, 2008 at 10:27 pm
Of course I snuck in a little plug :)
As Peter said, there are plenty of people that don't agree with me though and some well-written comments. Worth a read just for that.