|
The following diagram shows the architecture of a typical J2EE application. This is similar to the previous example,except all business logic is contained in different EJB components.

The diagram below shows how the JSP connects to the EJB object,which queries the database. This was the JSP does not contain the database queries and some business logic has been moved into the EJB layer. The EJB container is designed to create copies (instances) of the EJB class as required in memory. This enables it to scale up as multiple requests come in.

Advantages.
Disadvantages.
All the JSP pages need to include code that locates the EJB components.
There is still quite a bit of functionality in the JSP files.
The current architecture does not support reuse at the JSP level so all the code will need to be replicated. This will cause major maintenance problems.
The JSP pages are still too complex for web designers to use.
|