Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>As you have found, you can disable the shared cache, see <a href="http://wiki.eclipse.org/EclipseLink/Examples/JPA/Caching" rel="noreferrer">http://wiki.eclipse.org/EclipseLink/Examples/JPA/Caching</a> or <a href="http://wiki.eclipse.org/EclipseLink/FAQ/How_to_disable_the_shared_cache%3F" rel="noreferrer">http://wiki.eclipse.org/EclipseLink/FAQ/How_to_disable_the_shared_cache%3F</a></p> <p>There are also other options available in EclipseLink depending on your data and requirements.</p> <p>A list of option include:</p> <ol> <li><p>Disable shared cache</p></li> <li><p>Enable cache coordination (see, <a href="http://www.eclipse.org/eclipselink/api/2.1/org/eclipse/persistence/config/PersistenceUnitProperties.html#COORDINATION_PROTOCOL" rel="noreferrer">http://www.eclipse.org/eclipselink/api/2.1/org/eclipse/persistence/config/PersistenceUnitProperties.html#COORDINATION_PROTOCOL</a>)</p></li> <li><p>Set a cache invalidation timeout (see, <a href="http://www.eclipse.org/eclipselink/api/2.1/org/eclipse/persistence/annotations/Cache.html#expiry%28%29" rel="noreferrer">http://www.eclipse.org/eclipselink/api/2.1/org/eclipse/persistence/annotations/Cache.html#expiry%28%29</a>)</p></li> <li><p>Enable optimistic locking, this will ensure that any stale object cannot be updated, when an update on stale data occurs it will fail, and EclipseLink will automatically invalidate the object in the cache.</p></li> <li><p>Investigate the Oracle TopLink integration of EclipseLink and Oracle Coherence to provide a distributed cache.</p></li> </ol> <p>See also, <a href="http://en.wikibooks.org/wiki/Java_Persistence/Caching#Caching_in_a_Cluster" rel="noreferrer">http://en.wikibooks.org/wiki/Java_Persistence/Caching#Caching_in_a_Cluster</a></p> <p>There is no perfect solution, the solution used normally depend on the data/class, normally an application has a set of read-only classes, read-mostly classes and write mostly classes. Personally I would enable the cache for the read-only with a 1 day timeout, enable the cache with cache coordination for the read-mostly, and disable the cache for the write mostly.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload