Cayenne Solution [Re:Java Data Objects are nice..]
on
Java Data Objects
·
· Score: 1
While I am trying to stay away from commenting on EJB (the whole state of affairs in this area is just making me sad), among the real O/R frameworks (be it JDO-compatible or not), there are 3 major solutions:
Use bytcode "enhancements" (JDO)
Use reflection
Use common superclass
Personally I am in favor of (3). This allows to solve a problem mentioned by the parent - tracking object changes - with as little overhead as possible, and still keep your system clean OO. This is how Cayenne O/R Framework works:
This allows to track changes to objects as they occur, instead of doing a blanket analysis of all objects on commit. And in general this allows a better control of objects persistence behavior by the framework. There is another (commercial) product that uses the same approach: NeXT/Apple's WebObjects.
The downside of (3) is that you must have a common superclass for all your business objects, but I still have to see the case when this is undesirable.
Andrus
Disclaimer: I am personally involved with Cayenne and therefore not impartial:-)
Personally I am in favor of (3). This allows to solve a problem mentioned by the parent - tracking object changes - with as little overhead as possible, and still keep your system clean OO. This is how Cayenne O/R Framework works:
http://objectstyle.org/cayenne/
This allows to track changes to objects as they occur, instead of doing a blanket analysis of all objects on commit. And in general this allows a better control of objects persistence behavior by the framework. There is another (commercial) product that uses the same approach: NeXT/Apple's WebObjects. The downside of (3) is that you must have a common superclass for all your business objects, but I still have to see the case when this is undesirable.
Andrus
Disclaimer: I am personally involved with Cayenne and therefore not impartial :-)