You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@isis.apache.org by "Daniel Keir Haywood (Jira)" <ji...@apache.org> on 2021/07/15 16:36:00 UTC
[jira] [Created] (ISIS-2799) JPA: Framework caches and does not
re-read changed state from the database.
Daniel Keir Haywood created ISIS-2799:
-----------------------------------------
Summary: JPA: Framework caches and does not re-read changed state from the database.
Key: ISIS-2799
URL: https://issues.apache.org/jira/browse/ISIS-2799
Project: Isis
Issue Type: Bug
Components: Isis Persistence JPA
Affects Versions: 2.0.0-M5
Reporter: Daniel Keir Haywood
Assignee: Daniel Keir Haywood
Fix For: 2.0.0-M6
It seems that we use
the symptom seems to be that we cache EntityManager's in JpaContext, which might be ok if they are proxied thread-locals; however the underlying aren't disposed of.
We notice that EclipseLink creates a "NoServerPlatform", meaning that it doesn't recognise us as being in a container.
We also notice that JPA creates an LocalContainerEntityManagerFactoryBean, whereas perhaps it should create a LocalEntityManagerFactoryBean. [https://stackoverflow.com/a/6157339/56880]
some docs:
[https://www.eclipse.org/eclipselink/documentation/2.6/solutions/testingjpa001.htm]
[https://www.baeldung.com/jpa-hibernate-persistence-context] - we want to use "transaction-scoped" persistence context rather than "extended" ... and we are, I think.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)