During the migration of the rails 2 application to rails 3, I encountered a huge increase in memory usage. After some research, I found out that assistants were a problem. Exposing any helpers in the view will speed everything up.
Things I was trying to find in a real problem:
- include_all_helpers = false
- disable parts of auxiliary files
- clear code by refactoring Model.all uses faster code
Now I have the theory that some helpers can be renamed or deleted, the rails begin to search for them and begin to search for models / controllers as a salvation.
A page request takes up to 5 seconds and uses 2 GB of memory.
Has anyone understood what is causing this problem, and how to fix or debug it?
source share