The pieces that make up the J2EE architecture can be divided into three categories, as can be seen in Figure 10-1.
Components: Reusable, encapsulated program elements.
Containers: The runtime environments for components that mediates between the components and connectors.
Services: Providers of access to external services via standard APIs.
There are three types of components defined in the J2EE model. These are:
Java Server Pages (JSPs)
Enterprise JavaBeans (EJBs)
Servlets and JSPs are components designed specifically for building Web-based applications ...