Hi,

which version of OJB do you use?
Did you try the default ObjectCache implementation? Same result?
How does your code look like?

regards,
Armin

Sylvain ~ wrote:
Hi,

I'm trying to create crossreferenced objects, as specified in the
Cache documentation :

 "It allows to perform circular lookups (as by crossreferenced
objects) that would result in non-terminating loops without such a
cache."

I Use ObjectCachePerBrokerImpl since my application is multi-threaded
(and runs on tomcat)

The problem is that I get a java.lang.StackOverflowError, when trying
to do so with theses classes (simplified for clarity). both classes
have auto-retrieve="true".

Any Idea to make it work would be appreciated.
Sylvain.

public class User {

/**
* --- PK ---
* @ojb.field primarykey="true"
* autoincrement="ojb"
*/
private Integer pk=null;
/**
* user room
* @ojb.reference * foreignkey="pk"
*/
private Room room;


    }

public class Room {

/**
* --- PK ---
* @ojb.field primarykey="true"
* autoincrement="ojb"
*/
private Integer pk=null;
/**
* Students in this room
* @ojb.collection * foreignkey="fk"
* element-class-ref="kdms.core.persistent.User"
* auto-update="true"
* auto-retrieve="true"
* auto-delete="false"
*/
private Vector users;
}


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to