Hi, after unmarshalling an object hierarchy, with 'masterobject = ZitatDB.unmarshal(new FileReader("example.xml"))', i was trying to make it persistent, i.e. i do a 'db.create(masterobject)', but i kept running into:
------------- [TEST] Castor: Creating zitatdb.ZitatDB (null) java.lang.StackOverflowError at org.exolab.castor.persist.ClassMolder.getPriority(Unknown Source) . . . at org.exolab.castor.persist.ClassMolder.getPriority(ClassMolder.java:635) Exception in thread "main" ------------- So, i looked up the line 635 in ClassMolder.java and found a hint to bug #963. I wanted to post to your list, but fortunately, after an upgrade to your daily snapshot from cvs no stackoverflow occured anymore and it turned out to be my bad: i had forgotten one call to set a backlink to master for bi-directional reference in a add-operation of master class ZitatDB. Plus another mistake: i used name instead of many-key attribute for a 1:1 reference in the master class mapping (field element). Now, it works so far :-) My object hierarchy looks similar to attached gif (except for some SourceGenerator generated descriptors classes, an extra class QuelleTypChoice and some superclasses: "Typ"). Thanks for Castor! + Regards, dan PS Smaller problem: how to code the {or} restriction for the QuelleTypChoice (see attached diagram) - please feel free if some idea comes to your mind :-)
<<attachment: data_model.gif>>