In what way is Ruby on Rails NOT multithreaded?
Disclaimer: I'm a c# ASP.NET developer learning "RoR". Sorry if this question doesn't "get" RoR, any corrections greatly appreciated!
What is multithreading
My understanding of "multithread" ability in web apps is twofold:
- Every time a web/app server receives a request it can assign a thread to the new request, thus multiple requests can run concurrently.
- The app runtime + language allows for multiple threads to be used WITHIN a single request (in ASP.NET via "Async" methods and keywords for example).
In this way, IIS7 + ASP.NET can do points 1 AND 2.
I'm confused about RoR
I've read these two articles and they have left me confused:
- Clearing up some things about LinkedIn mobile’s move from Rails to node.js
- How to deploy a multi-threaded Rails app
question one.
I think I understand that RoR doesn't lend itself very well to point number 2 above, that is, having multiple threads within the same request, have I got that right?
question two.
Just to be crystal clear, RoR app/web servers can also do point number 1 above right (that is, multiple requests can run concurrently)? is that not always the case with RoR?
请先登录再写评论。
There are answers on the StackOverflow where you've posted this question so I'll leave a link to it just in case anyone else has similar questions:
http://stackoverflow.com/questions/12766456/in-what-way-is-ruby-on-rails-not-multithreaded