Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EclipseLink » StackOverFlow(StackOverFlow OneToOne and OneToMany)
icon9.gif  StackOverFlow [message #755308] Tue, 08 November 2011 03:33 Go to next message
Caio  is currently offline Caio Friend
Messages: 4
Registered: November 2011
Junior Member
Hi for all,

I have started project with EclipseLink... thats great... but, I got stackoverflow with this scenario:
Entities : ClassList, lvlupgain and skilltrees.
ClassList have a column id and it can be referenced for lvlupgain and skilltrees.
ClassList -> lvlupgain (OneToOne)
ClassList -> skilltrees (OneToMany)

ClassList = 89
lvlupgain = 89
skill_trees = 13722

 public void loadData() {
        EntityManagerFactory emf;
        emf = Persistence.createEntityManagerFactory("TestRelationshipPU");
        ClassListJpaController jpa = new ClassListJpaController(emf);
        List<ClassList> listData = jpa.findClassListEntities();
        for (ClassList classList : listData) {
            System.out.println("classList" + classList.getClassName());

[EL Info]: 2011-11-08 01:08:30.682--ServerSession(9202071)--EclipseLink, version: Eclipse Persistence Services - 2.2.0.v20110202-r8913
[EL Info]: 2011-11-08 01:08:31.644--ServerSession(9202071)--file:/D:/Projects/TestRelationship/src/_TestRelationshipPU login successful
Exception in thread "main" java.lang.StackOverflowError
	at org.eclipse.persistence.internal.sessions.AbstractSession.getDescriptor(
	at org.eclipse.persistence.internal.sessions.AbstractSession.getDescriptor(
	at org.eclipse.persistence.internal.sessions.UnitOfWorkImpl.registerExistingObject(
	at org.eclipse.persistence.mappings.ObjectReferenceMapping.buildUnitofWorkCloneForPartObject(
	at org.eclipse.persistence.mappings.ObjectReferenceMapping.buildCloneForPartObject(

What cause this error? Thanks so much for your help and NICE Project!!!

Re: StackOverFlow [message #756020 is a reply to message #755308] Thu, 10 November 2011 13:56 Go to previous message
James Sutherland is currently offline James SutherlandFriend
Messages: 1939
Registered: July 2009
Location: Ottawa, Canada
Senior Member

Include more of the stack trace.

Are you using LAZY relationships, does the error occur if you do?

Include your code for the classes. Have you mapped the Id correctly, what cache type are you using?

James : Wiki : Book : Blog : Twitter
Previous Topic:StackOverFlow
Next Topic:SDO/POJO Bridge
Goto Forum:

Current Time: Fri May 25 01:37:59 GMT 2018

Powered by FUDForum. Page generated in 0.01391 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top