12.11.2014 Views

web server - Borland Technical Publications

web server - Borland Technical Publications

web server - Borland Technical Publications

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Chapter<br />

15<br />

15Entity Beans and Table Mapping for<br />

Chapter<br />

CMP 2.0<br />

Important<br />

Here we'll examine how entity beans are deployed in the <strong>Borland</strong> Enterprise Server<br />

and how persistence of entities can be managed. This is not, however, an introduction<br />

to entity beans and should not be treated as such. Rather, this document will explore<br />

the implications of using entity beans within <strong>Borland</strong> Partitions. We'll discuss descriptor<br />

information, persistence options, and other container-optimizations. Information on the<br />

<strong>Borland</strong>-specific deployment descriptors and implementations of Container-Managed<br />

Persistence (CMP) will be documented in favor of general EJB information that is<br />

generally available from the J2EE Specifications from Sun Microsystems.<br />

For documentation updates, go to www.borland.com/techpubs/bes.<br />

Entity Beans<br />

Entity beans represent a view of data stored in a database. Entity beans can be finegrained<br />

entities mapping to a single table with a one-to-one correspondence between<br />

entity beans and table rows. Or, entity beans can span multiple tables and present data<br />

independent of the underlying database schema. Entity beans can have relationships<br />

with one another, can be queried for data by clients, and can be shared among<br />

different clients.<br />

Deploying your Entity Bean to one of the <strong>Borland</strong> Enterprise Server Partitions requires<br />

that it be packaged as a part of a JAR. The JAR must include two descriptor files: ejbjar.xml<br />

and the proprietary ejb-borland.xml file. The ejb-jar.xml descriptor is fullydocumented<br />

in the J2EE 1.3 Specification. The DTD for ejb-borland.xml is reproduced<br />

in this document and aspects of its usage documented here. The <strong>Borland</strong> proprietary<br />

descriptor allows for the configuration of a number of properties that can be set to<br />

optimize container performance and manage the persistence of your entity beans.<br />

Chapter 15: Entity Beans and Table Mapping for CMP 2.0 127

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!