Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Duplicate
-
None
-
None
-
None
-
None
-
JPA 2.3.0
Description
I cannot seem to get the evict by OID working. When I use evict by class that works, but what I really want to do is to just evict a single entity.
Here is my scenario:
1) Bean managed EJB uses a native SQL to modify an Entity. This does begin & commit.
2) After the commit it makes a call to another EJB, but that call is returning stale data.
I have tried:
OpenJPAEntityManager kem = OpenJPAPersistence.cast(em);
kem.getEntityManagerFactory().getCache().evict(X.class, id);
But that doesn't work, but this works:
OpenJPAEntityManager kem = OpenJPAPersistence.cast(em);
kem.getEntityManagerFactory().getCache().evictAll(X.class);
Am I the only one having issues with evict by ID?
Attachments
Issue Links
- is cloned by
-
OPENJPA-2506 StoreCache interface doesn't work for many ID types
- Closed