Skip Headers

# Understanding the EJB Entity Beans With CMP Architecture

Previous

Next

CMP is the part of the J2EE component model that provides an object persistence service that an EJB container uses to persist entity beans. CMP provides distributed, transactional, secure access to persistent data, with a guaranteed portable interface.

This architecture is an extension of the three-tier architecture, in which the implementation of persistence methods is handled by the container at runtime. As a bean provider, you only need to specify in a deployment descriptor those persistent fields and relationships for which the container must handle data access and, optionally, an abstract representation of the database schema.

TopLink CMP is an extension of the TopLink persistence framework that provides custom integration to EJB containers of various application servers (see "Application Server Support"). For more information about choosing an application server, see "Understanding Target Platforms". TopLink integrates with the EJB container in this architecture to augment (or, in the case of OC4J, become) the container's persistence manager.

Note: When using OC4J and Java 1.5, TopLink supports a subset of the persistence features anticipated in the final EJB 3.0 specification. For more information on EJB 3.0 support, see Oracle Containers for J2EE Enterprise JavaBeans Developer's Guide. EJB 3.0 feature support is subject to change and dependent upon the contents of the final specification.

TopLink CMP integration is nonintrusive (see Figure: Three-Tier CMP Architecture). Through a combination of run-time integration and code generation, the container uses TopLink internally and the bean user interacts with entity beans with container-managed persistence according to their standard API. This lets you combine the standard interfaces and power of CMP and a container with TopLink flexibility, performance, and productivity.

Three-Tier CMP Architecture

Description of "Three-Tier CMP Architecture"

For more information, see the following:

- "Integrating TopLink With an Application Server "

- "Creating TopLink Files for Deployment"

- "Packaging a TopLink Application"

- "Deploying a TopLink Application"

- "Configuring Persistence Type"