openjpa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hthom...@apache.org
Subject svn commit: r1531176 - in /openjpa/branches/2.2.1.x: ./ openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/ openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/ openjpa-persistence-jdbc/src/test/java/org/apac...
Date Fri, 11 Oct 2013 02:44:07 GMT
Author: hthomann
Date: Fri Oct 11 02:44:06 2013
New Revision: 1531176

URL: http://svn.apache.org/r1531176
Log:
OPENJPA-2330: Stackoverflow due to endless recursive calls - back ported to 2.2.1.x Rick Cutis's
changes to trunk.

Added:
    openjpa/branches/2.2.1.x/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/TestOpenJPA2330.java
      - copied unchanged from r1448662, openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/TestOpenJPA2330.java
    openjpa/branches/2.2.1.x/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityA.java
      - copied, changed from r1448662, openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityA.java
    openjpa/branches/2.2.1.x/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityB.java
      - copied, changed from r1448662, openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityB.java
    openjpa/branches/2.2.1.x/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityC.java
      - copied, changed from r1448662, openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityC.java
Modified:
    openjpa/branches/2.2.1.x/   (props changed)
    openjpa/branches/2.2.1.x/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/inheritance/jointable/onetomany/
  (props changed)
    openjpa/branches/2.2.1.x/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/OpenJPAPersistenceUtil.java

Propchange: openjpa/branches/2.2.1.x/
------------------------------------------------------------------------------
  Merged /openjpa/trunk:r1448662,1448796

Copied: openjpa/branches/2.2.1.x/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityA.java
(from r1448662, openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityA.java)
URL: http://svn.apache.org/viewvc/openjpa/branches/2.2.1.x/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityA.java?p2=openjpa/branches/2.2.1.x/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityA.java&p1=openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityA.java&r1=1448662&r2=1531176&rev=1531176&view=diff
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityA.java
(original)
+++ openjpa/branches/2.2.1.x/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityA.java
Fri Oct 11 02:44:06 2013
@@ -31,7 +31,7 @@ import javax.persistence.Id;
 import javax.persistence.OneToMany;
 import javax.persistence.OrderColumn;
 
-@Entity
+@Entity(name="oaopeEntityA")
 public class EntityA implements Serializable {
 
     private static final long serialVersionUID = 0L;

Copied: openjpa/branches/2.2.1.x/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityB.java
(from r1448662, openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityB.java)
URL: http://svn.apache.org/viewvc/openjpa/branches/2.2.1.x/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityB.java?p2=openjpa/branches/2.2.1.x/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityB.java&p1=openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityB.java&r1=1448662&r2=1531176&rev=1531176&view=diff
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityB.java
(original)
+++ openjpa/branches/2.2.1.x/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityB.java
Fri Oct 11 02:44:06 2013
@@ -31,7 +31,7 @@ import javax.persistence.ManyToOne;
 import javax.persistence.OneToMany;
 import javax.persistence.OrderColumn;
 
-@Entity
+@Entity(name="oaopeEntityB")
 public class EntityB {
     private static final long serialVersionUID = 0L;
     @Id

Copied: openjpa/branches/2.2.1.x/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityC.java
(from r1448662, openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityC.java)
URL: http://svn.apache.org/viewvc/openjpa/branches/2.2.1.x/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityC.java?p2=openjpa/branches/2.2.1.x/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityC.java&p1=openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityC.java&r1=1448662&r2=1531176&rev=1531176&view=diff
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityC.java
(original)
+++ openjpa/branches/2.2.1.x/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/entity/EntityC.java
Fri Oct 11 02:44:06 2013
@@ -26,7 +26,7 @@ import javax.persistence.Id;
 import javax.persistence.ManyToOne;
 import javax.persistence.Version;
 
-@Entity
+@Entity(name="oaopeEntityC")
 public class EntityC {
     @Id
     @GeneratedValue(strategy = GenerationType.IDENTITY)

Propchange: openjpa/branches/2.2.1.x/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/inheritance/jointable/onetomany/
------------------------------------------------------------------------------
  Merged /openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/inheritance/jointable/onetomany:r1448662,1448796

Modified: openjpa/branches/2.2.1.x/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/OpenJPAPersistenceUtil.java
URL: http://svn.apache.org/viewvc/openjpa/branches/2.2.1.x/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/OpenJPAPersistenceUtil.java?rev=1531176&r1=1531175&r2=1531176&view=diff
==============================================================================
--- openjpa/branches/2.2.1.x/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/OpenJPAPersistenceUtil.java
(original)
+++ openjpa/branches/2.2.1.x/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/OpenJPAPersistenceUtil.java
Fri Oct 11 02:44:06 2013
@@ -152,6 +152,9 @@ public class OpenJPAPersistenceUtil {
                     return LoadState.NOT_LOADED;
                 }
             }
+            if (pcs != null && pcs.contains(sm)) {
+                return LoadState.LOADED;
+            }
             FieldMetaData[] fmds = sm.getMetaData().getFields();
             // Check load state of all persistent eager fetch attributes
             if (fmds != null && fmds.length > 0) {



Mime
View raw message