Oracle TopLink Developer's Guide
10g Release 3 (10.1.3) B13593-01 |
|
Previous |
Next |
Java-to-data source integration is a widely underestimated problem when creating enterprise Java applications. This complex problem involves more than simply reading from and writing to a data source. The data source elements include tables, rows, columns, and primary and foreign keys. The Java and J2EE include entity classes (regular Java classes or Enterprise JavaBeans (EJB) entity beans), business rules, complex relationships, and inheritance. In a nonrelational data source, you must match your Java entities with EIS records or XML elements and schemas. These differences (as shown in Figure 1-2) are known as the object-persistence impedance mismatch.
Figure 1-2 Solving Object-Persistence Impedance Mismatch
Successful solution requires bridging these different technologies, and solving the object-persistence impedance mismatch–a challenging and resource-intensive problem. To solve this problem, you must resolve the following issues between J2EE and data source elements:
Fundamentally different technologies
Different skill sets
Different staff and ownership for each of the technologies
Different modeling and design principles
Application developers need a product that enables them to integrate Java applications with any data source, without compromising ideal application design or data integrity. In addition, Java developers need the ability to store (that is, persist) and retrieve business domain objects using a relational database or a nonrelational data source as a repository.
TopLink Solution
TopLink addresses the disparity between Java objects and data sources. TopLink is a persistence framework that manages relational, object-relational, EIS, and XML mappings in a seamless manner. This allows developers to rapidly build applications that combine the best aspects of object technology and the specific data source. TopLink enables you to do the following:
Persist Java objects to virtually any relational database supported by a JDBC-compliant driver.
Persist Java objects to virtually any nonrelational data source supported by a J2EE Connector architecture (J2C) adapter using indexed, mapped, or XML enterprise information system (EIS) records.
Perform in-memory conversions between Java objects and XML Schema (XSD) based XML documents using JAXB.
Map any object model to any relational or nonrelational schema, using the Oracle TopLink Workbench graphical mapping tool.
Use TopLink successfully, even if you are unfamiliar with SQL or JDBC, because TopLink offers a clear, object-oriented view of data sources.