Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [eclipselink-users] stackoverflow in eclipselink

Hello Yannick,

Just going down the first 350 lines of the stack trace, it shows it is building an object model of the form:
OneToOneMapping - noindirection
CollectionMapping(transparent indirection is used, but triggered possibly by a joining hint on the mapping or query) CollectionMapping(transparent indirection is used, but triggered possibly by a joining hint on the mapping or query)
OneToOneMapping - noindirection
OneToOneMapping - noindirection
OneToOneMapping - noindirection
OneToOneMapping - noindirection
CollectionMapping(transparent indirection is used, but triggered possibly by a joining hint on the mapping or query)

The rest looks very similar. My guess is the object tree has numerous references that are allowing a large tree to be brought in and build due to indirection not being used and lazy collections being triggered with joining. Please take a look at the object model and see if one of the OneToOne mappings couldn't be using indirection, or if there are options set on a OneToMany or ManyToMany that shouldn't be.

Best Regards,
Chris


On 28/06/2011 8:34 AM, Yannick Majoros wrote:
 Hi,

Le 28/06/2011 14:28, Tom Ware a écrit :

The most common reason people run into stack overflow exceptions is disabling the cache and then accessing a cycle of EAGER mappings (or accessing a chain of LAZY mappings without weaving enabled)

cache isn't disabled. It's an EJB/JPA application: EAR, about 20 modules maintained by different persons. Some come has been ported from toplink (= still using eclipselink api).

  What version of EclipseLink are you using?

The one included in Glassfish 3.1

  What query are you running?  Are there any hints?

No hints, lazy/eager annotations.

How are the objects retreived by the query mapped (including objects they are related to)?

Some in a lazy way, most using jpa but some with native api.

  How have you set up the EclipseLink cache?

  What are your logging settings.
persistence.xml:
<?xml version="1.0" encoding="UTF-8"?>
<persistence version="2.0" xmlns="http://java.sun.com/xml/ns/persistence"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd";>
<persistence-unit name="EpcPU" transaction-type="JTA">
<provider>org.eclipse.persistence.jpa.PersistenceProvider</provider>
<jta-data-source>jdbc/epcCurrent</jta-data-source>
<properties>
<property name="eclipselink.target-database" value="Oracle"/>
<property name="eclipselink.logging.level" value="WARNING" />
<property name="eclipselink.logging.level.sql" value="FINE" />
<property name="eclipselink.logging.parameters" value="true" />
</properties>
</persistence-unit>
</persistence>


Entities and persistence.xml are in a jar that is included in every ejb module (at least), which makes it a shared persistence unit.

Thank you,

Yannick
_______________________________________________
eclipselink-users mailing list
eclipselink-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/eclipselink-users


Back to the top