Interface QueryResultsCache
public interface QueryResultsCache
Responsible for managing query result list caching in a specific
query cache region. There may be
multiple instances of
QueryResultsCache, corresponding to
second-level cache regions with distinct policies.
A QueryResultsCache depends on the TimestampsCache
to track invalidation of the query spaces (tables) which affect the
cached queries. A cached query result list is considered stale
if any one of the query spaces which affect the query results was
invalidated since the result
list was read from the database and stored in the
query result cache.
-
Method Summary
Modifier and TypeMethodDescriptionvoidclear()default voiddestroy()Deprecated, for removal: This API element is subject to removal in a future version.This noop method is never calledList<?> get(QueryKey key, String[] spaces, SharedSessionContractImplementor session) Attempt to retrieve a cached query result list for the givenQueryKeyfrom the cache region, and then check if the cached results, if any, are stale.List<?> get(QueryKey key, Set<String> spaces, SharedSessionContractImplementor session) Attempt to retrieve a cached query result list for the givenQueryKeyfrom the cache region, and then check if the cached results, if any, are stale.The underlying cache region being used.booleanput(QueryKey key, List<?> result, SharedSessionContractImplementor session) Store a result list of a query with the givenQueryKeyin the query result cache.
-
Method Details
-
getRegion
The underlying cache region being used. -
clear
- Throws:
CacheException
-
destroy
Deprecated, for removal: This API element is subject to removal in a future version.This noop method is never called
-