RailsCasts Pro episodes are now free!

Learn more or hide this

Jakub Głuszecki's Profile

GitHub User: cthulhu666

Site: http://backtothefront.net

Comments by Jakub Głuszecki

Avatar

Very interesting episode, I'm just trying to implement this idea in my rails app to improve performance.
However Ryan's middleware fails if some of batch requests has status other than 200, e.g. 404:

ERROR NoMethodError: undefined method `join' for #<ActionDispatch::Response:0x378f9b20>

this error comes from last line of 'process_request' method.
I changed that line to:

{status: status, headers: headers, body: (status == 200 ? body.join : nil)}

and it seems to work, but I'm not sure if this is bulletproof, so I will appreciate any thoughts on this

Avatar

Does anyone know how to change default jvm options (heap size, stack size) that trinidad_init_services uses to generate init script ?

Avatar

Thank You, I missed the episode 337, with base.rb in place it's working now

Avatar

I have some problems regarding 'trinidad:setup' step.
You mentioned 'trinidad_init_services' gem, but after all it isn't used, right ?
When trying to run 'cap trinidad:setup' I got an error:

.rvm/gems/ruby-1.9.3-p194/gems/capistrano-2.12.0/lib/capistrano/configuration/variables.rb:122:inmethod_missing_with_variables': undefined method set_default' for #<Capistrano::Configuration:0x00000002002218> (NoMethodError)