I found one answer here from DZone snippets.
In rails console:
ActiveRecord::Base.logger = Logger.new(STDOUT)
ActiveRecord::Base.clear_active_connections!
One thing that makes this not the most ideal answer is that if you need to do a hard reload of the rails console (not reload!
), then you will have to punch these lines in again. It would be nice if there was a way to keep the profiling running in a background process.