![]() |
![]() |
|
| Index | Recent Threads | Unanswered Threads | Who's Online | Help |
|
|
| No member browsing this thread |
|
Thread Status: Active Total posts in this thread: 6
|
|
| Author |
|
|
Expert UK Joined: Mar 13, 2004 Post Count: 5686 Status: Offline |
You can read about this new feature here http://datanucleus.blogspot.com/2009/01/jdo-23-metadata-api.html ---------------------------------------- -Andy ![]() ![]() |
||
|
|
Expert Joined: Nov 16, 2005 Post Count: 1009 Status: Online |
Nice, very nice. Having the possibility to access metadata with an API instead of parsing XML and reimplementing .jdo/.orm files retrieval algorithms is great. I know that you can specify orm-specific properties in .jdo files but I really don't like: I would prefer Guido ---------------------------------------- Guido Anzuoni http://www.objectmagic.org |
||
|
|
Expert UK Joined: Mar 13, 2004 Post Count: 5686 Status: Offline |
I know that you can specify orm-specific properties in .jdo files but yes I know, and FWIW I agree totally on the principle of keeping ORM info out of basic persistence information (which is why all DN docs stress this), but providing a split causes implementation issues since ORM info is distributed through the whole metadata "file", on every element with some attributes being ORM and some being JDO. So we'd have to force people to "create" 2 metadata objects - one for JDO and one for ORM, and if they had multiple classes in their metadata object then this would get complicated. Also it complicates the implementation, and not got the time for that right now PS. I just updated the blog entry to now include the access to XML/annotation based metadata, as well as mentioning that you can use toString() on the JDO metadata object to get the XML representation that it equates to. ---------------------------------------- -Andy ![]() ![]() ---------------------------------------- [Edit 1 times, last edit by andy at Jan 27, 2009 3:32:16 PM] |
||
|
|
Newbie Joined: Mar 7, 2008 Post Count: 18 Status: Offline |
I read the blog article about this topic. I am particularly excited about being able to programmatically create persistence meta data. For use with RDBMS I have one question though: How could DB schema creation be handled in a scenario with no external (XML) and only programmatically created meta data - if at all? "autoCreateSchema" is not a valid option for most use cases I'm sure. How could the SchemaCreator (e.g. launched from Ant) receive the required meta data? |
||
|
|
Expert UK Joined: Mar 13, 2004 Post Count: 5686 Status: Offline |
Doing things in-memory is not limited to metadata definition http://www.jpox.org/servlet/wiki/pages/viewpage.action?pageId=6619188 You can create classes (ASM), define their metadata ("JDO2.3 Metadata API"), enhance them ("JDO2.3 Enhancer API"), run schematool on them (DataNucleus), and even persist them (JDO) ... without anything actually in your filesystem. Or you can do a subset of the above ---------------------------------------- -Andy ![]() ![]() |
||
|
|
Newbie Joined: Mar 7, 2008 Post Count: 18 Status: Offline |
Lots of nice information there. Thanks a lot! ![]() |
||
|
|
|
|
|
Current timezone is GMT May 17, 2012 12:05:49 PM |