Home arrow Java arrow Page 2 - Web Development in J2EE Using the MVC Design Pattern
JAVA

Web Development in J2EE Using the MVC Design Pattern


Web services application development is a huge topic covering a broad range of technologies and topics. In this article we will discuss Web services development in J2EE and examine the Model/View/Controller design pattern, thereby explaining how it separates business logic implementation and persistence from presentation. We shall briefly introduce the Struts Framework, one that facilitates web services development within the IBM WebSphere Studio Application Developer edition. (This article was originally published in the June 2004 issue of Plug-In).

Author Info:
By: Dwight Peltzer
Rating: 4 stars4 stars4 stars4 stars4 stars / 34
January 17, 2005
TABLE OF CONTENTS:
  1. · Web Development in J2EE Using the MVC Design Pattern
  2. · Examining Servlets and Java Server Pages
  3. · Java Server Pages (JSPs) Resolve Servlet Issues
  4. · Applying the Model/View/Controller Design Pattern
  5. · Applying the Mediator Design Pattern

print this article
SEARCH DEVARTICLES

Web Development in J2EE Using the MVC Design Pattern - Examining Servlets and Java Server Pages
(Page 2 of 5 )

The process described above occurs in a Java J2EE environment by using Java Servlets for processing client requests and delegating the requested task(s) to a Java Bean or an Enterprise JavaBean (EJB) for data persistence or retrieval. Subsequently, the Servlet utilizes a Java Server Page (JSP) to return the response or results to the client. J2EE specifications provide support for Web development and offer numerous alternatives for creating Web applications. Java Servlets have become increasingly popular in recent years and interact seamlessly with JSPs.  Servlets offer the advantage of being written in Java, implementing presentation logic and managing Web browser client requests.

Additionally, they create a single heavyweight process and facilitate user requests by using a lightweight thread maintained by the Java Virtual Machine. A servlet is designed to map to one or more URLs. When the server receives a specified servletís URL request, the service() method is invoked and subsequently responds. Each request is associated with an individual client call. This allows multiple users to invoke the service method simultaneously, a major benefit for users.

Unfortunately, servlets also have a negative side. HTML is hard coded, making modifications to a servlet difficult because for every change, a servlet recompile is necessary. Also, determining a userís locale, language, and other variants is difficult to accomplish in HTML. In fact, internationalization issues are frequently bypassed in Web development because a unique servlet is required for each individual locale. This is altogether too cumbersome.  There must be another answer.


blog comments powered by Disqus
JAVA ARTICLES

- Java Too Insecure, Says Microsoft Researcher
- Google Beats Oracle in Java Ruling
- Deploying Multiple Java Applets as One
- Deploying Java Applets
- Understanding Deployment Frameworks
- Database Programming in Java Using JDBC
- Extension Interfaces and SAX
- Entities, Handlers and SAX
- Advanced SAX
- Conversions and Java Print Streams
- Formatters and Java Print Streams
- Java Print Streams
- Wildcards, Arrays, and Generics in Java
- Wildcards and Generic Methods in Java
- Finishing the Project: Java Web Development ...

Watch our Tech Videos 
Dev Articles Forums 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
Contact Us 
Site Map 
Privacy Policy 
Support 

Developer Shed Affiliates

 




© 2003-2017 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap
Popular Web Development Topics
All Web Development Tutorials