About merge

11-20 of 108Refresh
Forum
20

Memory leak while merging parent with No Cascade annotation with children

the merging object db implementation. The test case is the following, just run and watch the "Memory Used" by comparing Cascade.ALL (or Cascade.MERGE ) to nothing. Tested with last version of Object Db ( 2.5.5 ... .valueOf(i)));                 em.merge(e);             }             if (! em.getTransaction
Forum
20

Merge of entity classes with "mapped by" very slow

Hi, I have found a strange behavior when merging entities with "mapped by" set on @OneToMany relation. Even if object is fetched with find on the same transaction, merge is very slow. It's because on merge every single relation marked as LAZY is fetch from database. Attached two examples
Forum
20

NullpointerException when execute a merge

that is persisted with "merge()". Then we want to persist “merge()” an new object of a different type ... .OBC.onObjectDBError(OBC.java:1503) at com.objectdb.jpa.EMImpl.merge(EMImpl.java:526) at com.btc.ep ... ) at com.objectdb.jpa.EMImpl.merge(EMImpl.java:523) ... 43 more   But if we use enhanced classes
Issue
20

New entity objects are duplicated on merge cascading

When merge is cascaded to a new entity object that has not been persisted ... ();         em.getTransaction().begin();         book.chapters = Arrays.asList(new Chapter());         em.merge ... )         private Long id;     }        }     Fixing this bug may require totally new implementation of merge
Issue
20

Unexpected exception (Error 990) - Merge with no Transaction

I am frequently having an error when merging a detached object outside of a transaction ... ();      em.merge(a).setValue("second version");      em.getTransaction().commit();      em.close();      em = emf.createEntityManager();         a = em.merge(a);         System.out.println
Forum
20

Problem on JPA Merge Entity.

Hello, I have a problem with the EntityManager.merge() function. I set a property value ... (ERGOClass ergoClass) throws DaoException { entityManager.merge(ergoClass); } } Thanks ... merge issue or Spring / JPA transaction management issue? Maybe it is a missing @Transactional
Forum
20

Merge failure with composite primary key

) (error 631) at com.objectdb.jpa.EMImpl.merge(EMImpl.java:451) at MergeTest.main(MergeTest.java:19)   Thanks. Thank you for the test case. It clearly demonstrates a new problem in merging non managed entity objects (calling merge on a new non persistent object), and build 2.3.7_21 should fix
Forum
19

javax.persistence.EntityNotFoundException using merge

I am trying to persist a new object using merge operation.But I am getting javax.persistence.EntityNotFoundException . When working with other JPA implementor it works fine. I need to use merge beause I need to get the reference to the managed instance of the created object. I am using ObjectDB 2.3
Forum
19

Merge with Parent/Child entities not possible

long id;   @ManyToOne(fetch = FetchType.LAZY, cascade = { CascadeType.PERSIST, CascadeType.MERGE ... = entityManager.merge(parentEntityNew);   entityManager.getTransaction().commit();   entityManager
Forum
19

Issue with merge in 2.4.3

Hi, we just tried to upgrade to 2.4.3 from 2.4.2. One of our regression tests is failing. Appears objects are getting created twice on merge. Please see attached unit test. Thanks Paul. This regression bug was the result of a bad optimization that is now fixed in build 2.4.3_01. pedwards eitane