Effective Enterprise Java: Writing a foreward for Ted AO gaining use, or at least interest
Sep 13

What should go in the annotations for “transparent persistence”

Tech Add comments

JSR 250: Common Annotations for the Java Platform is out there, and you can request to join the expert group.

The scope is hard to work out:

This JSR will develop annotations for common semantic concepts in the J2SE and J2EE platforms that apply across a variety of individual technologies.

What does this mean?

I agree with the desire to standardize on annotations. That is needed, else we will have a million annotations for the same thing (we need the equiv of java.lang.* and java.package.* and ….).

However, I worry that we will have a group making decisions that should be deferred. Again, this group could be an unbrella group for others which come up with more specialised topics… which yet shouldn’t be in their own specs.

For example, OR mapping can be shared between JDO and EJB (although I would prefer that there was ONE transparent persistence spec… but I won’t go there ;).

I would rather see a small spec/group formed for this. Then we get to the next point, which is what would we want to annotate here.

I agree with some of the JDO expert group that want to restrict annotations to the model (@Persistent, @Inverse), and we don’t clutter it with deployment info (@Table(Name=”FOO”)).

And if I see raw SQL in the annotations. Ewww!

Leave a Reply

Spam is a pain, I am sorry to have to do this to you, but can you answer the question below?

Q: What are the first four letters in the word British?

Loading...