I'd like to profile a Rails app using ruby-prof and JMeter. I'm not interested in suggested methods of profiling particular controller/action/ or model method, I'd like to profile full stack, top to bottom.
So I run something like this:
RAILS_ENV=production ruby-prof -f prof.out script/server > /dev/null
Then I run my JMeter test plan on it. The problem however is that interrupting it with CTRL+C or SIGKILL kills ruby-prof too before it can write any output. How do I stop mongrel server without interrupting ruby-prof?
An alternative to running ruby-prof would be to deploy your application to a staging environment (or any sort of environment that replicates your production environment fairly closely), with newrelic performance monitoring, and then run a heavy load test on it from JMeter. I find that this more accurately replicates real-world performance, and you can always add newrelic custom metrics to your app if you need more fine-grained performance data than newrelic provides by default.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With