require 'debuglog' and record debugging information (including variable traces and timing information) to the file debug.log -- cheap and easy.
Gavin Sinclair
gem "debuglog", "~> 1.0.1"