openjpa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Ezzio (asmtp)" <dez...@bea.com>
Subject Preliminary design for supporting OpenJPA annotations in XML metadata.
Date Fri, 20 Jul 2007 20:00:35 GMT
Hi,

I'm starting to design support of XML metadata for OpenJPA annotations 
in order to address OpenJPA-125 and OpenJPA-87.

I've attached a zip containing a preliminary design document, a sample 
openjpa_orm_1_0.xsd file and a sample OpenJPA ORM instance.

It took quite a while to create the text document and it is best viewed 
as the tracks of a design process.  The design that I worked on the most 
(the one with the most documentation) is not necessarily the best 
design.  There are two alternatives suggested, and there may be others 
that I haven't thought of.

I think the fundamental choices facing us are these:

1. Do we construct an OpenJPA ORM schema that extends the JPA ORM 
schema?  Doing so, allows the user to use one metadata file instead of 
two, and will enhance maintainability for our users' applications.  Or 
do we construct a standalone OpenJPA ORM schema?  I've chosen the first 
option in the preliminary design, and I think it is the best choice.

2. Do we use a syntactically loose "extension" element format or do we 
construct new elements for each supported annotation?  Choosing the 
first makes it easy (I think) to support newly added annotations. 
Choosing the second allows the schema validator to do most of the 
validation work.  I've chosen the first option in the preliminary 
design, but I'm not at all sure of the choice.

3. Do we envision support in XML for all OpenJPA annotations or for only 
a subset?  If a subset, how do we draw a bright line that will be 
consistent and easily documented and followed over time?  I've chosen 
the first option in the preliminary design simply because that is the 
brightest line that I can think of and because it gave me a chance to 
look over the field of OpenJPA annotations.

I'll be off on vacation for a week with very limited Internet 
connections, so please, take as much time as necessary to consider the 
design, and carry on some discussions without me if the spirit moves you.

Thanks,

David Ezzio

Mime
View raw message