Defines the integration aspect of Hibernate's second-level caching allowing "caching back ends" to be plugged in as a caching provider.
RegionFactoryis the main integration contract that defines how Hibernate accesses the provider. It's main contract is the generation of
Regionreferences with the requested intent (what will be stored there). Generally a provider will integrate with Hibernate by: 1. implementing the contracts in
org.hibernate.cache.spi2. implementing the contracts in
org.hibernate.cache.spi.support3. a mix of (1) and (2) The first approach allows for more control of the set up, but also requires more to implement. The second approach tries to minimize the amount of work needed to integrate with caching providers to basically the
DomainDataStorageAccesscontracts which are basic read/write type abstractions of the underlying "cache" object - it is a nearly complete implementation aside from providing the proper "storage access" objects. Note: providers may also integrate with Hibernate via Hibernate's JCache support as defined by the `hibernate-jcache` module - no code involved aside from being a JCache implementation properly registered via the JCache spec.
Interface Summary Interface Description CacheImplementor CacheKeysFactory CacheTransactionSynchronizationDefines a context object that a
RegionFactoryis asked to create (
RegionFactory.createTransactionContext(org.hibernate.engine.spi.SharedSessionContractImplementor)}) when a Hibernate Session is created.
DirectAccessRegionSpecialized Region whose data is accessed directly (not requiring key/item wrapping). DomainDataRegionA Region for cacheable domain data - entity, collection, natural-id. ExtendedStatisticsSupportOptional Region contract defining support for extra statistic information QueryKey.ParameterBindingsMementotodo (6.0) : integrate work from original 6.0 branch QueryResultsCacheDefines the responsibility for managing query result data caching in regards to a specific region. QueryResultsRegionDefines the contract for a cache region which will specifically be used to store query results. RegionContract for a named "region". RegionFactoryContract for building second level cache regions. SecondLevelCacheLogger TimestampsCacheWrapper for a
TimestampsRegionadding handling of stale results
TimestampsCacheFactoryResponsible for building the
TimestampsCacheto use for managing query results with respect to staleness of the underlying tables (sometimes called "query spaces" or "table spaces").
Class Summary Class Description AbstractCacheTransactionSynchronization AbstractRegionFactory FilterKeyAllows cached queries to be keyed by enabled filters. QueryKeyA key that identifies a particular query with bound parameter values. QuerySpacesHelper StandardCacheTransactionSynchronization