[OJB-developers] recursive dependency with ODMG
Brought to you by:
thma
From: <Joa...@tp...> - 2002-05-07 15:10:49
|
Hy, We're having a problem with recursive Dependencies with ODMG. We got a Class A and a Class B, Class A has a reference to a object of Class B and vice versa. when two objects a (of type A) and b (of type B) reference each other ODMG gets caught in an endless loop and finally throws a StackOverFlow-Error... the first few lines of the stack-trace follow: java.lang.StackOverflowError at java.util.Properties.getProperty(Properties.java:480) at java.lang.System.getProperty(System.java:574) at sun.security.action.GetPropertyAction.run(GetPropertyAction.java:66) at java.security.AccessController.doPrivileged(Native Method) at sun.io.Converters.getDefaultEncodingName(Converters.java:66) at java.lang.StringCoding.decode(StringCoding.java:224) at java.lang.String.<init>(String.java:380) at org.gjt.mm.mysql.Buffer.readLenString(Unknown Source) at org.gjt.mm.mysql.MysqlIO.getResultSet(Unknown Source) at org.gjt.mm.mysql.MysqlIO.sqlQueryDirect(Unknown Source) at org.gjt.mm.mysql.Connection.execSQL(Unknown Source) at org.gjt.mm.mysql.PreparedStatement.executeQuery(Unknown Source) at ojb.broker.accesslayer.JdbcAccess.materializeObject(JdbcAccess.java:327) at ojb.broker.singlevm.PersistenceBrokerImpl.getDBObject(Unknown Source) at ojb.broker.singlevm.PersistenceBrokerImpl.getObjectByIdentity(Unknown Source) at ojb.odmg.ObjectEnvelope.setInitialModificationState(Unknown Source) at ojb.odmg.ObjectEnvelope.<init>(Unknown Source) at ojb.odmg.TransactionImpl.register(Unknown Source) at ojb.odmg.TransactionImpl.lock(Unknown Source) at ojb.odmg.TransactionImpl.lockReferences(Unknown Source) at ojb.odmg.TransactionImpl.register(Unknown Source) at ojb.odmg.TransactionImpl.lock(Unknown Source) (Don't know yet why ojb.odmg is "Unknown Source", I'll have to find out). I don't know if I'm trying to do something that's not possible with ODMG (in which case I think we should throw the correct Exception) or if it's a simple bug. I will probably be able to provide a small test case by tomorrow, if needed. regards Joachim Sauer |