
With JPOX 1.2 you can persist using either the JDO or
JPA APIs. You should choose the API that meets your overall requirements.
The APIs have many similarities, and the design of the persistence layer of your application will be largely
unaffected by this choice. JPA is designed around relational datastores and its nomenclature is to a high degree
tied to such datastores. JDO, on the other hand, is designed to be datastore agnostic. Consequently JDO
is more suitable when using a datastore such as DB4O, and both are suitable for
RDBMS. JPA is a subset of JDO and consequently by choosing JDO you have an API that
is more complete.
The first thing to do when designing the datastore layer is to define your classes to be persisted (aka your "model").
You define this with either XML MetaData or annotations (or a mix of both). As well as defining which classes and
which fields of these classes are persisted you also have to specify how the "identity" of each object is defined.