When building a predominantly dynamic site using the Model 2 pattern, are there any good reasons to also put static pages (i.e., those that could be written in just HTML) under Model 2 control as well?

Ryan Breidenbach

Sure. There is really no reason not to include static content while using the Model 2 design.

For example, if you have a page that requires no "backend" processing, such a static FAQ or information page, then you can link directly to this page instead of going through a controller servlet. And if you have your Web Server (e.g. Netscape Enterprise Server) and your App Server (e.g. Weblogic) separate, this would save your app server processing time, since the web server would simply serve up the static HTML file.

Conversely, if you have an HTML form that does require some processing, you can call a servlet to initially handle the request. There is no reason that once the servlet processes the data that it can't forward the request to a static page (HTML or JSP) where appropriate. An example of this would be using a servlet to process a customer survey, persist the feedback, and forward to a static page that displays a "canned" thank you message.

Basically, if a page is not required to display dynamic content, why not keep it a static HTML page?