Hi all,
I am noticing some odd behavior with Grape in Heroku. Requests are coming back extremely slowly and New Relic tells me that Grape::Middleware::Formatter.call requests are the key source of the problem. Unfortunately my version of New Relic doesn't give me deeper detail, but Grape middle-ware only calls are taking up to 500ms to execute. This is with DB hits, application code, and other externalities removed in reporting.
A couple extra points:
- This behavior does not occur on my local development machine (a recent macbook pro).
- The Gemfile.lock is identical on my local dev machine and on Heroku (it is attached).
- I'm using Unicorn.
- I've locked my version of Rails (principally used for ActiveRecord) and Ruby.
- I am running two Heroku 2x dynos (1g of ram)
- Heroku and New Relic report that memory is holding stable about about 40% of the available and that the CPU is not going wild.
I'm at a bit of a loss to explain what's happening. Does anyone have any insight into this?
Best regards,
Adam Hiatt