Subject: Re: About NetBSD server tuning!
To: None <wojtek@wojtek.from.pl>
From: David Brownlee <abs@netbsd.org>
List: port-i386
Date: 02/23/2001 17:32:49
On Fri, 23 Feb 2001 wojtek@wojtek.from.pl wrote:
> > Are you using mod_perl or fastcgi on the server? Switching
> > a heavy perl/postgresql cgi client to fastcgi increased its
> > apachebench top rate from 1.8 hits per second to over 80.
>
> the best solution is to write CGI in C so it will not by VERY slow as perl
> is.
The big cost with perl is startup. If you have a requirement
well suited to perl's hashing datastructures and features its
hard to significantly outperform running perl with running c
without a lot of work.
Unless your program is trivial the selection of fastcgi over cgi
is more significant than between c and perl.
The program in question is not that large (its an online fantasy
system with everything pulled from a SQL database), but it has to
dynamically process templates and languages in a way that would
have made it uneconomic to write it in c.
Horses for courses.
David/absolute -- www.netbsd.org: No hype required --