I have a Rails 4 application that returns a large amount of data that is rendered as JSON (23K records/2.8MB document). Testing this call on my laptop using the WEBrick server, the request completes in 573ms.
Completed 200 OK in 573ms (Views: 0.1ms | ActiveRecord: 51.2ms)
If I switch over to Apache with Phusion Passenger the same exact request takes 3025ms to complete.
Completed 200 OK in 3025ms (Views: 0.1ms | ActiveRecord: 53.9ms)
I can't figure out why Passenger would be so much slower. Any thoughts out there?
My development environment is running OS X 10.7.5. I have Apache 2.2.24 and Passenger 4.0.23 installed.