Pro JSF and Ajax



an individual's machine and that controls interaction with business logic. These one-tier appli-
cations all integrate three application layers (presentation, business logic, and data), making it
hard to maintain and almost impossible to share and scale information.

Two-Tier: Client-Server
Two-tier, or client-server, solutions took center stage in the 1980s and pushed one-tier solu-
tions into the history archives. A two-tier architecture, which enables sharing data, changed
the way applications were developed and deployed. Two-tier applications directly interact with
the end user; business and presentation logic are stored on the client, and data resides on
a remote server. This architecture allows multiple users to access centralized data with appli-
cations such as desktop email clients (such as Microsoft Outlook or Mozilla Thunderbird).
Although the two-tier solution solves the issue of having multiple users accessing the same
data source, it also has its limitations, such as the lack of flexibility of the design to later modi-
fication or porting, which in turn increases maintenance costs.

Multitier: Web Applications
The next phase in application development arrived with the Internet and the Web browser
and introduced the three-tier, or multitier, architecture. In the one-tier solution, presenta-
tion, business logic, and data are all integrated in one monolithic application. The multitier
architecture breaks this type of application into three layers, allowing developers to focus on
specific domain areas--model (data access), view (presentation), and controller (logic). This
programming paradigm, representing the split between these layers, is known as the Model-
View-Controller (MVC) architecture and was first introduced in SmallTalk and spread to the
developer community in the 1980s.

Splitting the one-tier application into layers--in combination with a standard client (for
example, the Web browser) and a standard communication protocol (for example, Hypertext
Transfer Protocol [HTTP])--suddenly gave users ubiquitous access to centralized and familiar
applications such as email via a browser (for example, Google's browser-based Gmail). Applica-
tions are no longer something that only come on a CD or are downloaded. A multitier solution
gives the application owner centralized maintenance and administration, which allows the
application owner to provide instantaneous upgrades for everyone using the application.

Exploring Application Development Today
In this new world of multitier applications, developers need to keep up-to-date with emerg-
ing technologies and standards provided through such organizations as the World Wide Web
Consortium (W3C) and the Java Community Process (JCP). The industry is evolving, which
is good, but this also adds pressure on the application developer to always be building

C H A P T E R 1
s
T H E F O U N D AT I O N O F J S F : C O M P O N E N T S
5