Quoting David Dyer-Bennet (dd-b at dd-b.net): > > Yes, mod_perl can help here, but servlets still scale better. > > That's not a total surprise. Um, were you thinking of the thing whose > name I can't remember that lets you do perl embedded in the page > (which I think depends on mod_perl), or is there something clever to > do with mod_perl itself that helps directly? (Kinda ignorant about > mod_perl obviously). The Apache/Perl integration project brings together the full power of the Perl programming language and the Apache HTTP server. With mod_perl it is possible to write Apache modules entirely in Perl. In addition, the persistent interpreter embedded in the server avoids the overhead of starting an external interpreter and the penalty of Perl start-up time. http://perl.apache.org/ > I note you talk almost entirely about memory use here; and obviously > that's a strong reason you or anybody might be driven off Perl on a > heavily-used dynamic site. Any feeling for other performance > measures? Ok, soapbox time, this is not flamebait. It will probably show my ignorance on how far perl has come. Hopefully some perl mongers are here so they can set me right. When I was "into" perl, it was ver 4.x, so there probably lots of things that I _think_ perl can't do, or does badly that are now "fixed" in 5.5 or 5.6. Servlets are faster, especially when dealing with large database queries. In particular, objects that deal with lookup tables. Because servlets are persistent, you can at start up time perform one-time initialization routines. For instance, you DB table of the Countries. In this table is the full country name (United States of America), the ISO designation (US), optional short name (USA) and an application specific number. At start-up of the servlet container you can hit the DB and put resultSet into an efficient lookup object like a red-black tree or something a little more flexible like a hashtable. This is done just once, at boot time. Now access to this object are all done quickly from memory, because the servlet is persistent. Using perl, you have to hit the DB each time for this result (perl monger flame?). I know php has something similar, so sort of cache thing. Servlets "perform" better in an international community. While most Americans thing the Internet is "ours". Internet is global. One of our clients is an international organization in over 25 countries. Java's localization APIs make an international web site not only possible, but relatively easy. Java has native thread support with priorities. So servlets can "perform" nicely with each other more easily. One particular application I wrote has a "long" (60-120 seconds) processing cycle. The information is not time sensitive. So putting this request into a very low priority thread helps servlets scale. I don't think perl can do this (perl monger flame?), so ever perl cgi is give same priority. Servlets perform better with legacy systems and non-Unix based systems (ok, perl mongers are going to have to flame me on this). These are all things I could do under Java (easily) that I could not do under perl or was difficult to do under perl. Talking to MS SQL Server is no different then talking to MySQL or Postgres. It's all JDBC. Wanna talk XML, there is Xerces-J (yes, there is Xerces-perl too). Printing html from your browser not good enough? Converting the data from html into a pdf via FOP is no problem. Need to produce a fancy report with SVG (scalable vector graphics)? Grab Batik and you got everything you need. What to keep your DB object, Business Objects and Presentation (html) Object _TOTALLY_ separate so you can yank out the html and replace with wxml, wap or iDEN? Grab Enhydra and you got it made in the shade. Think working with the request/response model of web request is a step backwards? Grab Barracuda and change your web application into a Model2 Event Model machine (just like Swing). Is keeping your production, development and deployment servers in-sync a nightmare? Bundle all of your Java objects, images, and config files into a WAR (web archive) and just distribute 1 file for easy upgrades. I'll get off my soapbox now. -- Bob Tanner <tanner at real-time.com> | Phone : (952)943-8700 http://www.mn-linux.org | Fax : (952)943-8500 Key fingerprint = 6C E9 51 4F D5 3E 4C 66 62 A9 10 E5 35 85 39 D9