> I think that the lack of class unloading/reloading is the major factor
> that will keep real sites from using JSPs. Take our site for example
> (http://www.klgroup.com). We want a more "interactive" site, but
> we don't want multiple sets of pages - all pages should be managed
> using a single technology. Can JSPs do that? No, we'd end up having
> way to many classes loaded into memory for all those mostly static
> pages.

Let's say you have 5000 most static pages (why use JSP then?), and each
generates a big class file that takes up 50KB, that would 256MB.  That's a
lot of memory to use, but also it's really not that much these days.  Heck,
you buy a PC with 512MB of RAM for $1800 or so, and that's a reasonable
expense I'd say for a site with 5000 pages!

In many ways, JSP can save pages because of the dynamic builds.  For
example, I have a single JSP that generates hundreds or event thousands of
different pages (from a webcrawler's or human's perspective) because there's
only one program, and the data comes for a DB.  For example, with a message
board system, I need one JSP that lists the contents of the boards, another
JSP that lets you reply to the posting, and another JSP for posting a brand
new message.  So, I have three JSP files loaded in memory, yet I can handle
unlimited numbers of message boards, each with unlimited numbers of
messages.  Well, unlimited is limited by my DBMS.

But, I would like to see better use of plain old HTML files for static
content work with JSPs better.  It's a shame that pointing to an HTML file
causes session loss for non-cookie visitors.  And it's a shame that a JSP
can "read in the static part" of an HTML file at runtime (something like the
caching done by Apache) rather than converting it all into out.println()
calls.  Then, you could change the static HTML and the servlet would only
read it in again if the file changed or if it was unloaded from cache.  I
think we'll see these performance refinements coming soon.

We'll also the containers unloaded unused JSPs/servlets too.  Such
improvements always come later, since the real world tends to get things
done and makes them work first, then performance improvements come next as
people see the problems and where the best bang for the buck will be.

David

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
FAQs on JSP can be found at:
 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html

Reply via email to