Skip to content

Caching

Nikhil Purushe edited this page Mar 22, 2017 · 2 revisions

requery supports by default weak reference entity caching through WeakEntityCache.

  • Selecting a given entity through a query results in that entity being reused and it's fields updated
  • Relational collections, fetching a given entity through another entities collection (e.g. OneToOne, ManyToMany, etc) results in that entity being reused
  • Deleting a entity evicts the reference

Other types of caching available:

  • SerializableEntityCache JSR-107 JCache based entity caching
  • LayeredEntityCache layered cached that delegates into multiple EntityCache implementations
  • Caching can also be disabled through the Configuration object.