Java
  Home arrow Java arrow Page 10 - Overview of Java Web Technologies, Part 2
Dev Shed Forums  
Administration  
AJAX  
Apache  
BrainDump  
DHTML  
Flash  
Java  
JavaScript  
Multimedia  
MySQL  
Oracle  
Perl  
PHP  
Practices  
Python  
Reviews  
Security  
Smartphone Development  
Style-Sheets  
Web Services  
XML  
Zend  
Zope  
Mobile Linux  
App Generation ROI  
IBM® developerWorks  
Forums Sitemap  
E-Commerce Hosting  
Linux Web Hosting  
Managed Hosting  
Small Business Hosting  
VPS Hosting  
Weekly Newsletter

 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid  
Request Media Kit
Contact Us  
Site Map  
Privacy Policy  
Support  
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
JAVA

Overview of Java Web Technologies, Part 2
By: McGraw-Hill/Osborne
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: starstarstarstarstar / 8
    2004-03-03


    Table of Contents:
  • Overview of Java Web Technologies, Part 2
  • Sun's Solution
  • JSP and JavaBeans
  • Calling a Bean from a JSP Page
  • Accessing Bean Properties
  • Custom Tags
  • Developing and Using Custom Tag Libraries
  • Writing a Tag Handler
  • Writing and Using Tags
  • Model 2 Architecture

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      error-file:tidyout.log Del.ici.ous error-file:tidyout.log Digg
      error-file:tidyout.log Blink error-file:tidyout.log Simpy
      error-file:tidyout.log Google error-file:tidyout.log Spurl
      error-file:tidyout.log Y! MyWeb error-file:tidyout.log Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article

     
     
    ADVERTISEMENT


    Overview of Java Web Technologies, Part 2 - Model 2 Architecture
    ( Page 10 of 10 )

    Java Web application can be designed based on Model 1 or Model 2. Model 1 is for very small applications that will never grow more complex and consists of JSP pages only. Each JSP page references another JSP page, making maintenance very hard as the application grows bigger. The Model 2 architecture is the recommended design model for medium sized and large applications, and is based on the Model-View-Controller (MVC) pattern. A Model 2 architecture is indicated by the presence of a controller servlet between the client browser and the JSP pages (or the servlets that present the content). See Figure 6. The controller servlet dispatches HTTP requests to the corresponding presentation JSP pages—based on the request URL, input parameters, and application state. In this model, presentation parts (JSP pages or servlets) are isolated from each other.

    JSP


    Figure 6 Model 2 Architecture

    Model 2 applications are more flexible and easier to maintain, and to extend, because views do not reference each other directly. The Model 2 controller servlet provides a single point of control for security and logging, and often encapsulates incoming data into a form usable by the back-end MVC model.

    JSF is based on the Model 2 architecture, in which there is one controller servlet and multiple JSP pages. The controller servlet is called Faces Servlet and is already provided by the JSF implementation. The development of a JSF application focuses on the authoring of JSP pages and the writing of other components.

    Summary

    To start developing JSF applications, you need to be familiar with servlets and JSP technologies and related technologies, especially JavaBeans and custom tag libraries. It is also helpful if you are familiar with the Model 2 architecture as JSF is based on this design model. This chapter provided a brief review of the four technologies as well as the Model 2 architecture. For more details on these technologies you should consult a servlet/JSP book, such as my own “JavaWeb Development with Servlets, JSP, and EJB, Second Edition” (Sams Publishing, 2004).

    Buy this book now!Remember: This is part two of the first chapter of JavaServer Faces Programming, by Budi Kurniawan (McGraw-Hill/Osborne, ISBN 0-07-222983). Stay tuned for more chapters of developer books from McGraw-Hill/Osborne.
    Buy this book!
     



     
     
    >>> More Java Articles          >>> More By McGraw-Hill/Osborne
     

       

    JAVA ARTICLES

    - Exception Handling Techniques in Java
    - More About Multithreading in Java
    - The Basics of Multiple Threads in Java
    - Data Access Using Spring Framework JDBC
    - New Object Initialization in Java
    - Adding Images With iTextSharp
    - Adding Columns With iTextSharp
    - Creating Simple PDF Files With iTextSharp
    - The Spring Framework: Understanding IoC
    - Introducing the Spring Framework
    - Java Classes
    - Completing the Syntactic Comparison of Java ...
    - Syntactic Comparison of Java and C/C++
    - Java Statements
    - Conditionals, Expressions and Other Java Ope...





    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 1 Hosted by Hostway
    Stay green...Green IT