Help

Built with Seam

You can find the full source code for this website in the Seam package in the directory /examples/wiki. It is licensed under the LGPL.

A three-tier application is a system in which clients are capable of holding application state. This naturally conflicts with state held in the middle tier, by the Seam application container. This working document is used in our ongoing analysis of how such an architecture could look like and what Seam can bring to the table.

The Triple Mapping Problem

The first issue you'd run into with a three-tier architecture is the triple entity mapping problem. The following illustration shows the problem:

In addition to the gap between the database and the middle tier, you also have to deal with the gap between the client and the middle tier. This is not a trivial issue that can be solved by some simple data-transfer object assembler. Consider this: The JPA engine (Hibernate...) bridges the gap between your server-side models and the (shared by many applications) data model in the database. Of course, the object/relational mismatch between pointers in the Java layer and key references in the database management system results in additional complexity. However, any other mapping problem that is commonly solved by introducing a JPA engine again rears its head when we transfer and map data between the client and server of the application.

(TBC)

3 comments:
 
01. Jun 2009, 21:22 America/New_York | Link

Any idea when this article is going to be continued? It looks like the start of some good information, but needs a lot more fleshing out.

 
23. Jun 2009, 12:27 America/New_York | Link
Please give some updates on what the ideal architecture of a seam - richfaces - Oracle 9i project would be.
 
08. Jul 2009, 18:27 America/New_York | Link
Joe Chung

This statement is not valid:

A three-tier application is a system in which clients are capable of holding application state.

A 3 tier app may be stateless (e.g. Spring/Hibernate) and not necessarily capable of holding application state.

The 3-Tier architecture has the following three tiers:

Presentation Tier
    This is the topmost level of the application. The presentation tier displays information related to such services as browsing merchandise, purchasing, and shopping cart contents. It communicates with other tiers by outputting results to the browser/client tier and all other tiers in the network.
Application Tier (Business Logic/Logic Tier)
    The logic tier is pulled out from the presentation tier and, as its own layer, it controls an application’s functionality by performing detailed processing.
Data Tier
    This tier consists of Database Servers. Here information is stored and retrieved. This tier keeps data neutral and independent from application servers or business logic. Giving data its own tier also improves scalability and performance. 

source: http://en.wikipedia.org/wiki/Multitier_architecture

also, there should be mention of MVC pattern in this article.