[rails][refactoring]railsのボトルネック探しツール railsを実装しているときに、N+1問題回避するためにincludeしたり、処理をかき変えたりするが、やるんだったら最小で最大の効果を上げたい。 むしろ意味の無い所のチューニングには時間を費やしたくない。 そんなときにお薦めなツールをQiitaで見つけたのでご紹介 miniprofiler 各ページ表示やSQLの処理時間を計測し、表示してくれるツール。 class ApplicationController < ActionController::Base protect_from_forgery before_filter :miniprofiler private def miniprofiler if Rails.env.development? || (current_user.try(:role) ==