On 27/09/06, Daniel Smedegaard B. [email protected] wrote:
I tried looking in my history, and I think this might be the post I
was thinking about:
http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-talk/211423But this guy is also using ADO anyway. And I have no way near enough
knowledge about Ruby or this guy’s particular problem to know why his
code fails.
He’s opening a second statement against a connection while he already
has one open. That’s not supported by dbi drivers, and not used
within rails.
Okay, I gotta know now. Why exactly would one keep IIS instead of just
running the Webrick server? Does it scale badly, or…? Do I get any
kind of extra features by integrating with IIS that I’d otherwise miss
out on?
Webrick is really just a toy server. It’s great for development, but
no way near stable/secure enough for production.
In place of Webrick many people use Mongrel, which is extremely easy
to set up and use and excels at serving rails applications (though not
great at static content). It also comes with excellent documentation,
and a very helpful userbase. However, Ruby on Rails is not thread
safe, so when running rails, only a single concurrent request can be
handled. This is a rails issue - Mongrel itself can handle concurrent
requests.
To get around this, most deployments run many mongrel processes on
each server, each on a different port. To distribute requests between
each mongrel instance, some form of load-balancer or proxy is used
(there seem to be loads to choose from, though I don’t know what
exactly what your options are on windows). One common solution is to
use Apache; it may be possible to use IIS but doesn’t seem exactly
recommended ![]()
Tom
