multithreading - How to run Rails multi-threaded in development? -


i working on multiple projects talk each other , i've run issue app

  1. a calls b (request 1, still running)
  2. b calls (request 2)
  3. based on request 2's result, b responds request 1

this requires me running multi-threaded rails in development mode.

i know can set using puma or ... isn't there simpler way?

i avoid changing in project (adding gems, config files..).

something rails s --multi nice, can't webrick run multiple threads or spawn more processes?

can perhaps install standalone gem need , run thin run . -p 3?

you can configure app multi-threaded un-commenting following line production.rb:

# config.threadsafe!

if run rails_env=production bundle exec rails server you'll start in production mode multi-threading. you'll have cross puma bridge either way, though, if , when deploy production server.


Comments

Popular posts from this blog

node.js - Node js - Trying to send POST request, but it is not loading javascript content -

javascript - Replicate keyboard event with html button -

javascript - Web audio api 5.1 surround example not working in firefox -