Cache level « Map « JPA Q&A





1. Hibernate Bi-Directional ManyToMany Updates with Second Level cache    stackoverflow.com

I have a bidirectional many-to-many class:

public class A{
 @ManyToMany(mappedBy="listA")
 private List<B> listB;
}
public class B{
 @ManyToMany
 private List<A> listA;
}
Now I save a listA into B:
b.setListA(listA);
This all works fine until I turn on ...

2. NHibernate parent-child relationship: does NH update parents in entity cache?    stackoverflow.com

If I update a child in a parent-child relationship, the child gets updated in the L2 cache. But what about the parent? Is it possible to do this without hitting the database? Thanks!

3. second level cache and entity inheritance    forum.hibernate.org

Does Hibernate use the cache for a parent entity if there is no explicit cache for a child entity of the parent? For example, say I have the following. Code: package test; @Entity public class Parent { } @Entity public class Child extends Parent { } ... ...

5. Second level cache and many-to-many mapping    forum.hibernate.org

Hibernate version:2.x Name and version of the database you are using:Oracle 9x I wonder if anybody ever ran into this situation before. I have a many-to-many association that I need to eager fetch. I have second level caching enable using OSCache. So i set outer-join=true in the element as well as in its (nested) element. Also set elements ...

6. problem overriding mapping (disables 2nd level cache) query    forum.hibernate.org

Hibernate version: 3.2 Mapping documents: APPL_MAIN_SEQ ... Name and version of the database you ...

7. Problem with 2nd level cache and unidirectional manyToOne    forum.hibernate.org

Regular Joined: Mon Aug 20, 2007 6:47 am Posts: 74 Location: UK Hibernate version: 3.2 2nd level cache: ehcache I'm having some difficulty with cached entitys. In particular, when I delete an entity that is the "one" side of a manyToOne unidirectional relationship. Please read the following example, where first of all I define two entities: Address and Person, where Person ...