Interface CacheBackend
public interface CacheBackend
Provides the cache primitives for a caching
Persistence facade, suitable for multiple
repositories. It is advisable to have one CacheBackend per Backend.-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionvoidlonggetReference(String realmId, String name) voidpurge()voidAdds the given object to the local cache and sends a cache-invalidation message to Polaris peers.voidAdds the given object only to the local cache, does not send a cache-invalidation message.voidputNegative(String realmId, ObjRef id) voidputReference(String realmId, Reference reference) Adds the given reference to the local cache and sends a cache-invalidation message to Polaris peers.voidputReferenceLocal(String realmId, Reference reference) Adds the given reference only to the local cache, does not send a cache-invalidation message.voidputReferenceNegative(String realmId, String name) voidvoidremoveReference(String realmId, String name) wrap(Persistence persist)
-
Field Details
-
NON_EXISTENT_REFERENCE_SENTINEL
Special sentinel reference instance to indicate that a reference object has been marked as "not found". This object is only for cache-internal purposes. -
NOT_FOUND_OBJ_SENTINEL
Special sentinel object instance to indicate that an object has been marked as "not found". This object is only for cache-internal purposes.
-
-
Method Details
-
get
-
put
Adds the given object to the local cache and sends a cache-invalidation message to Polaris peers. -
putLocal
Adds the given object only to the local cache, does not send a cache-invalidation message. -
putNegative
-
remove
-
clear
-
purge
void purge() -
estimatedSize
long estimatedSize() -
wrap
-
getReference
-
removeReference
-
putReference
Adds the given reference to the local cache and sends a cache-invalidation message to Polaris peers. -
putReferenceLocal
Adds the given reference only to the local cache, does not send a cache-invalidation message. -
putReferenceNegative
-